From: Alexandre Emsenhuber Date: Sun, 7 Aug 2011 12:28:58 +0000 (+0000) Subject: Readd basic headers and ... arround error contents that was removed... X-Git-Tag: 1.31.0-rc.0~28396 X-Git-Url: http://git.cyclocoop.org/%22.%24image2.%22?a=commitdiff_plain;h=952f9219819ffe075f88903a475aa4c7e73f4a87;p=lhc%2Fweb%2Fwiklou.git Readd basic headers and ... arround error contents that was removed in r90993. This caused display errors of UTF-8 characters due to the lack of these things in a DBConnectionError exception. --- diff --git a/includes/Exception.php b/includes/Exception.php index 5a972ca358..10a409cbd1 100644 --- a/includes/Exception.php +++ b/includes/Exception.php @@ -182,12 +182,25 @@ class MWException extends Exception { $wgOut->output(); } else { + header( $_SERVER['SERVER_PROTOCOL'] . ' 500 MediaWiki Error', true, 500 ); + header( 'Content-type: text/html; charset=UTF-8' ); + header( 'Cache-control: none' ); + header( 'Pragma: nocache' ); + $hookResult = $this->runHooks( get_class( $this ) . "Raw" ); if ( $hookResult ) { die( $hookResult ); } + echo " + + +" . $this->getPageTitle() . " + + +"; echo $this->getHTML(); + echo "\n"; die(1); } }