From: Chad Horohoe Date: Fri, 3 Dec 2010 13:46:21 +0000 (+0000) Subject: Fix for r76480: !$css was never true, since it always contained \n. This way also... X-Git-Tag: 1.31.0-rc.0~33615 X-Git-Url: http://git.cyclocoop.org/ecrire?a=commitdiff_plain;h=05f8f8e97058f61953889cd0d8f1399adf40102e;p=lhc%2Fweb%2Fwiklou.git Fix for r76480: !$css was never true, since it always contained \n. This way also lets us at least show one file if the other is inaccessible for less breakage. --- diff --git a/includes/installer/WebInstallerOutput.php b/includes/installer/WebInstallerOutput.php index 3dde274638..b4a013eea8 100644 --- a/includes/installer/WebInstallerOutput.php +++ b/includes/installer/WebInstallerOutput.php @@ -92,10 +92,12 @@ class WebInstallerOutput { $vectorCss = file_get_contents( $vectorCssFile ); $configCss = file_get_contents( $configCssFile ); wfRestoreWarnings(); - $css = str_replace( 'images/', '../skins/vector/images/', $vectorCss ) . "\n" . str_replace( 'images/', '../skins/common/images/', $configCss ); - if( !$css ) { - return "/** Your webserver cannot read $vectorCssFile or $configCssFile, please check file permissions */"; - } elseif( $dir == 'rtl' ) { + if( !$vectorCss || !$configCss ) { + $css = "/** Your webserver cannot read $vectorCssFile or $configCssFile, please check file permissions */"; + } + + $css .= str_replace( 'images/', '../skins/vector/images/', $vectorCss ) . "\n" . str_replace( 'images/', '../skins/common/images/', $configCss ); + if( $dir == 'rtl' ) { $css = CSSJanus::transform( $css, true ); } return $css;