When specifying a 404 error document in vBSEO cp, the header returned for 404 errors is 200 OK
This is far from ideal...
I even have header("HTTP/1.0 404 Not Found"); in my 404 php file... Is vBSEO over-riding this?
This is a discussion on custom 404 Error Doc returns 200 OK within the Troubleshooting forums, part of the vBSEO SEO Plugin category; When specifying a 404 error document in vBSEO cp , the header returned for 404 errors is 200 OK This ...
Hello Rob,
yes, the header should be sent from the included script and vBSEO doesn't prevent this. Make sure that header() is executed before the output starts.
Oleg Ignatiuk / Crawlability Inc.
Security vbulletin - Patch Level for all supported versions released!
Unveiling the NEW vBSEO Sitemap Generator 3.0. - available NOW for vBSEO Customers!
..... it is, this is php file:-Originally Posted by Oleg Ignatiuk
Yet it's still returning 200 OKCode:<?php // ####################### SET PHP ENVIRONMENT ########################### error_reporting(E_ALL & ~E_NOTICE); // #################### DEFINE IMPORTANT CONSTANTS ####################### define('NO_REGISTER_GLOBALS', 1); define('THIS_SCRIPT', '404.php'); / header("HTTP/1.0 404 Not Found"); // ################### PRE-CACHE TEMPLATES AND DATA ###################### // get special phrase groups $phrasegroups = array( ); // get special data templates from the datastore $specialtemplates = array( ); // pre-cache templates used by all actions $globaltemplates = array( '404_error', ); // pre-cache templates used by specific actions $actiontemplates = array( ); // ######################### REQUIRE BACK-END ############################ require_once('./global.php'); // ####################################################################### // ######################## START MAIN SCRIPT ############################ // ####################################################################### $domain = $_SERVER['HTTP_HOST']; $navbits = array(); $navbits[$parent] = 'Error 404 - Not Found'; $navbits = construct_navbits($navbits); eval('$navbar = "' . fetch_template('navbar') . '";'); eval('print_output("' . fetch_template('404_error') . '");'); ?>
This script returns 404 in my case, may be it's related to vBulletin? Please try a simple case like:
PHP Code:<?php
Header ("HTTP/1.1 404 Not Found");
echo 'Error 404 - Not Found';
?>
Last edited by Oleg Ignatiuk; 05-29-2006 at 04:18 PM.
Oleg Ignatiuk / Crawlability Inc.
Security vbulletin - Patch Level for all supported versions released!
Unveiling the NEW vBSEO Sitemap Generator 3.0. - available NOW for vBSEO Customers!
Great!
Oleg Ignatiuk / Crawlability Inc.
Security vbulletin - Patch Level for all supported versions released!
Unveiling the NEW vBSEO Sitemap Generator 3.0. - available NOW for vBSEO Customers!