homepage Welcome to WebmasterWorld Guest from 54.167.185.110
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Visit PubCon.com
Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
Forum Library, Charter, Moderators: coopster & jatar k

PHP Server Side Scripting Forum

    
404 not found followed by 30x redirect OK to do?
rudyten




msg:3624984
 10:33 pm on Apr 11, 2008 (gmt 0)

I ussually just display my 404 custom error page

But there are a couple of scenarios where I want to notify seach engines the page is not found "404" but I then want to redirect the visitor to a category page.

Is this ok to do? or bad for SEO? or just plain bad?

 

g1smd




msg:3625058
 1:06 am on Apr 12, 2008 (gmt 0)

A URL returns 404 as not found, or sends a redirect (301 or 302) to tell the visitor that the content has moved.

You can't send a 301 redirect after sending "404" in the header. That's not possible. The HTTP transaction is finished when the 404 is sent. Send just one or the other of the codes.

Just provide the right error message and supporting internal navigation right there on the 404 error page and let the visitor click one.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved