vBulletin Search Engine Optimization
This is a discussion on 301 OK vs. 301 Permanently Moved? within the Bug Reporting forums, part of the vBSEO SEO Plugin category; For some reason the headers being sent during a vBSEO redirect read 'HTTP/1.x 301 OK' instead of 'HTTP/1.x 301 Moved ...
| |||||||
Enhancing 80 million pages. | Register | FAQ | Members List | Social Groups | Calendar | Search | Today's Posts | Mark Forums Read |
|
#1
| ||||
| ||||
| 301 OK vs. 301 Permanently Moved?
For some reason the headers being sent during a vBSEO redirect read 'HTTP/1.x 301 OK' instead of 'HTTP/1.x 301 Moved Permanently'. Is this supposed to be the case? I see a similar issue with 404 errors at PHP.net PHP: header - Manual I think it has to do with PHP being run as CGI. If it is being run as CGI would you use... Code: header("Status: 301 Moved Permanently"); Code: header("HTTP/1.1 301 Moved Permanently"); Code: // This line of code was found in attachment.php
if (empty($_REQUEST['attachmentid']))
{
// return not found header
$sapi_name = php_sapi_name();
if ($sapi_name == 'cgi' OR $sapi_name == 'cgi-fcgi')
{
header('Status: 404 Not Found');
}
else
{
header('HTTP/1.1 404 Not Found');
}
exit;
}
Here are the captured headers from my sites 301 redirect with my notes in green.. Code: This line is the inital request sent from my browser RHCP in NJ tonight! - Chaos Forums And the actual get request from my browser... GET /showthread.php?t=1368 HTTP/1.1 Host: Chaos Forums User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.8.1.1) Gecko/20061204 Firefox/2.0.0.1 Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5 Accept-Language: en-us,en;q=0.5 Accept-Encoding: gzip,deflate Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 Keep-Alive: 300 Connection: keep-alive Cookie: chaosforumslastvisit=1170149015; chaosforumslastactivity=0; __utma=45672950.1751800113.1170149027.1170224728.1170307614.3; __utmz=45672950.1170224728.2.2.utmccn=(organic)|utmcsr=google|utmctr=%22agrobot%20phatbot%22|utmcmd=organic; chaosforumssessionhash=a917f68a1205fa72d23d2549c0f99d88; __utmb=45672950; __utmc=45672950; chaosforumscpsession=6e51f9786177166c391337f3f509b9be; chaosforumsuserid=1; chaosforumspassword=7361f224a4b2ca8bad4eebbe256f2eef Here is the response from the server with (what i think) is a faulty 301 redirect. HTTP/1.x 301 OK Date: Thu, 01 Feb 2007 06:35:48 GMT Server: Apache/1.3.37 (Unix) mod_fastcgi/2.4.2 mod_auth_passthrough/1.8 mod_log_bytes/1.2 mod_bwlimited/1.4 FrontPage/5.0.2.2635.SR1.2 mod_ssl/2.8.28 OpenSSL/0.9.7a PHP-CGI/0.1b X-Powered-By: PHP/4.4.4 Location: RHCP in NJ tonight! - Chaos Forums Keep-Alive: timeout=15, max=100 Connection: Keep-Alive Transfer-Encoding: chunked Content-Type: text/html |
|
#2
| ||||
| ||||
|
Hello Josh, in both cases 301 HTTP code is sent, so I don't think this is an issue, but we will add the code to handle cgi version of PHP in the next vBSEO build.
__________________ Oleg Ignatiuk / Crawlability Inc. vBSEO 3.2.0 Launched - Maximum Overdrive for Your Web Traffic! Over 100 Instant SEO Optimizations vBSEO Google Sitemap Generator - Version 2.2 Released Mandatory Upgrade for vBSEO 3.2.0 GOLD 6X Traffic - $1400 in One Day with vBSEO! Imagine What the vBSEO Patent Pending Technology Can Do For You. |
|
#3
| ||||
| ||||
|
Thank you Oleg! I wonder if malformed headers effect Google at all. All browsers seem to handle '301 OK' fine, I would assume spiders would too... O well, doesn't matter now, lol. Can't wait til' the next build! |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| moved from subdomain, which 301? | magnaromagna | URL Rewrite Settings | 7 | 09-10-2006 08:59 PM |
| 301 homepage | Ashley | General Discussion | 2 | 02-15-2006 06:34 AM |