X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FWebResponse.php;h=f5fb47fc5bbca1bcd34fb7866a61c8ae1a2976bc;hb=c78d1c842f7d4306cc20ffe4123e50fcf341fe76;hp=339b2e3ff0ac6f11851a3b707b9077de7d733325;hpb=3ba9b09378c94f8ce4075a5c95f2c1e2a4db8750;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/WebResponse.php b/includes/WebResponse.php index 339b2e3ff0..f5fb47fc5b 100644 --- a/includes/WebResponse.php +++ b/includes/WebResponse.php @@ -39,6 +39,9 @@ class WebResponse { * @param null|int $http_response_code Forces the HTTP response code to the specified value. */ public function header( $string, $replace = true, $http_response_code = null ) { + if ( headers_sent() ) { + MWDebug::warning( 'Headers already sent, should send headers earlier than ' . wfGetCaller() ); + } if ( $http_response_code ) { header( $string, $replace, $http_response_code ); } else {