Quote:
Originally Posted by Boothby
Those who have < PHP5.4 can add the following at the beginning of the error_generic plug-in and test it. This is a non standardized method, so it may or may not work.
PHP Code:
if (!function_exists('http_response_code'))
{
function http_response_code($newcode = NULL)
{
static $code = 200;
if($newcode !== NULL)
{
header('X-PHP-Response-Code: '.$newcode, true, $newcode);
if(!headers_sent())
$code = $newcode;
}
return $code;
}
}
source: http://www.liketly.com/forum/thread/...response-code/
Thanks to RolandCP for the hint.
|
Wow- I tested this on 3 forums (1 VB 3.8, 2 VB 4.x) and it worked fine on all 3. :up:
You should copy the code to the top of both plugins however.
Do you mind if I add the code to the plugin?