* @return string Remapped CSS
*/
protected static function remapStyle( $file ) {
- global $wgUseDataURLs, $wgScriptPath;
+ global $wgScriptPath;
return CSSMin::remap(
file_get_contents( self::remapFilename( $file ) ),
dirname( $file ),
$wgScriptPath . '/' . dirname( $file ),
- $wgUseDataURLs
+ true
);
}
}
// Startup function
$configuration = FormatJson::encode( $this->getConfig( $context ) );
$registrations = self::getModuleRegistrations( $context );
- $out .= "window.startUp = function() {\n\t$registrations\n\tmediaWiki.config.set( $configuration );\n};";
+ $out .= "var startUp = function() {\n\t$registrations\n\tmediaWiki.config.set( $configuration );\n};";
// Conditional script injection
$scriptTag = Xml::escapeJsString( Html::linkedScript( $wgLoadScript . '?' . wfArrayToCGI( $query ) ) );
- $out .= "if ( isCompatible() ) {\n\tdocument.write( '$scriptTag' );\n}\ndelete window['isCompatible'];";
+ $out .= "if ( isCompatible() ) {\n\tdocument.write( '$scriptTag' );\n}\ndelete isCompatible;";
}
return $out;