I am trying to get a responsive skin working in MediaWiki with media queries, and I was looking for some weird actions.
If I add a test div to the wiki page:
<div id="testing">TESTING</div>
And then add the media query:
@media screen {
#testing {background-color: green;}
}
... in different places, the style is applied only in certain browsers. For instance:
If I add it to the active skin "screen.css", where all the other working styles live:
- iPad: NO
- iPhone4: NO
- Chrome 20.0 XP + Mac: NO
- Firefox 14.0.1 XP + Mac: YES
If I add it to the shared skin "shared.css", which applies to all skins:
- iPad: NO
- iPhone4: NO
- Chrome 20.0 XP + Mac: NO
- Firefox 14.0.1 XP + Mac: YES
If I add it to the "MediaWiki: Common.css" wiki page:
- iPad: YES
- iPhone4: YES
- Chrome 20.0 XP + Mac: YES
- Firefox 14.0.1 XP + Mac: YES
N.B.: , . - , . , -, , MediaWiki. Firefox -?
, Chrome , , "load.php" , -; , , , .
- ? , .
Update:
, - Firefox , :
load.php:1 @media screen
#testing {
background-color: green;
}
Chrome Development Tools .
2:
:
<link rel="stylesheet" href="/wiki/load.php?debug=false&lang=en&modules=mediawiki.legacy.commonPrint%2Cshared%7Cskins.customskin&only=styles&skin=customskin&*" />
:
<link rel="stylesheet" href="wiki/skins/customskin/screen.css" />
.