}
function wfThumbError( $status, $msg ) {
+ global $wgShowHostnames;
header( 'Cache-Control: no-cache' );
header( 'Content-Type: text/html; charset=utf-8' );
if ( $status == 404 ) {
} else {
header( 'HTTP/1.1 500 Internal server error' );
}
+ if( $wgShowHostnames ) {
+ $url = htmlspecialchars( @$_SERVER['REQUEST_URI'] );
+ $hostname = htmlspecialchars( wfHostname() );
+ $debug = "<!-- $url -->\n<!-- $hostname -->\n";
+ } else {
+ $debug = "";
+ }
echo <<<EOT
<html><head><title>Error generating thumbnail</title></head>
<body>
<p>
$msg
</p>
+$debug
</body>
</html>