$msg .= "\n<p>Backtrace:</p>\n$backtrace";
}
}
- die( $msg );
+ echo $msg;
+ die( -1 );
}
function wfBacktrace() {
$pairs = array(
"\\" => "\\\\",
"\"" => "\\\"",
- "\'" => "\\\'",
+ '\'' => '\\\'',
"\n" => "\\n",
"\r" => "\\r",
wfProfileIn( $fname );
$notice = wfMsg( 'sitenotice' );
- if($notice == '<sitenotice>') $notice = '';
- # Allow individual wikis to turn it off
- if ( $notice == '-' ) {
+ if( $notice == '<sitenotice>' || $notice == '-' ) {
$notice = '';
- } else {
- if ($notice == '') {
- $notice = $wgSiteNotice;
- }
- if($notice != '-' && $notice != '') {
- $specialparser = new Parser();
- $parserOutput = $specialparser->parse( $notice, $wgTitle, $wgOut->mParserOptions, false );
- $notice = $parserOutput->getText();
- }
+ }
+ if( $notice == '' ) {
+ # We may also need to override a message with eg downtime info
+ # FIXME: make this work!
+ $notice = $wgSiteNotice;
+ }
+ if($notice != '-' && $notice != '') {
+ $specialparser = new Parser();
+ $parserOutput = $specialparser->parse( $notice, $wgTitle, $wgOut->mParserOptions, false );
+ $notice = $parserOutput->getText();
}
wfProfileOut( $fname );
return $notice;