X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Finstaller%2FWebInstaller.php;h=46348f917cef53a0164d0fa6789aa8e6a767e034;hb=a2dd652d9d14253683ca5fa93db0f19c36326605;hp=304508c4b6ea4f72cd79964798fa49da51dce374;hpb=6125d3fbf7bb046d2765d3ef058ea984871ca36c;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/installer/WebInstaller.php b/includes/installer/WebInstaller.php index 304508c4b6..46348f917c 100644 --- a/includes/installer/WebInstaller.php +++ b/includes/installer/WebInstaller.php @@ -61,7 +61,7 @@ class WebInstaller extends Installer { * To add a new installer page: * * Add it to this WebInstaller::$pageSequence property * * Add a "config-page-" message - * * Add a "WebInstaller_" class + * * Add a "WebInstaller" class * * @var string[] */ @@ -180,12 +180,9 @@ class WebInstaller extends Installer { return $this->session; } - $cssDir = $this->request->getVal( 'css' ); - if ( $cssDir ) { - $cssDir = ( $cssDir == 'rtl' ? 'rtl' : 'ltr' ); - $this->request->response()->header( 'Content-type: text/css' ); - echo $this->output->getCSS( $cssDir ); - + $isCSS = $this->request->getVal( 'css' ); + if ( $isCSS ) { + $this->outputCss(); return $this->session; } @@ -354,8 +351,6 @@ class WebInstaller extends Installer { restore_error_handler(); if ( $this->phpErrors ) { - $this->showError( 'config-session-error', $this->phpErrors[0] ); - return false; } @@ -462,7 +457,7 @@ class WebInstaller extends Installer { * @return WebInstallerPage */ public function getPageByName( $pageName ) { - $pageClass = 'WebInstaller_' . $pageName; + $pageClass = 'WebInstaller' . $pageName; return new $pageClass( $this ); } @@ -702,7 +697,8 @@ class WebInstaller extends Installer { $html = $this->parse( $text, true ); return "
\n" . - "escaped() . "\">" . + "escaped() . "\">" . wfMessage( 'config-help' )->escaped() . "\n" . "" . $html . "\n" . "
\n"; @@ -1157,4 +1153,19 @@ class WebInstaller extends Installer { return WebRequest::detectServer(); } -} \ No newline at end of file + /** + * Output stylesheet for web installer pages + */ + public function outputCss() { + $this->request->response()->header( 'Content-type: text/css' ); + echo $this->output->getCSS(); + } + + /** + * @return string[] + */ + public function getPhpErrors() { + return $this->phpErrors; + } + +}