homepage Welcome to WebmasterWorld Guest from 54.204.58.87
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / Apache Web Server
Forum Library, Charter, Moderators: Ocean10000 & incrediBILL & phranque

Apache Web Server Forum

    
using mod rewrite for 404
using mod_rewrite for 404
john1000




msg:3248941
 1:37 am on Feb 11, 2007 (gmt 0)

hi,

after some searching the forum i did run into a few topics that deals with almost same question i have but were still different...

What i want...
One of my sites i changed its content and chances are i will get requests on pages,html and php that doesnt exist anymore.

To take care of that i would like to use mod_rewrite.
sure i can use ErrorDocument 404 /
but if people go to page mysite.com/whatever.php (or html) i want every non existent request redirected to mysite.com/

How do i do that?

 

scriptmasterdel




msg:3248955
 2:18 am on Feb 11, 2007 (gmt 0)

Wouldn't it be more of an advantage to have a "301 Permanently Moved" redirect? This would work as an advantage on the Search Engines because the page would be found once all the new pages have been indexed, Instead of finding a blank page and loosing all the current search engine relevancy?

Just a thought.

Del

jdMorgan




msg:3248972
 2:40 am on Feb 11, 2007 (gmt 0)

> i want every non existent request redirected to mysite.com/

Not recommended -- Research "duplicate content" and "dup content penalty" for more info.

A better solution is to redirect those pages which do have an exact or "close enough" replacement to that replacement, make your custom 404 error page friendly and informative, and provide links on it to your home page and site map.

Jim

john1000




msg:3248977
 2:53 am on Feb 11, 2007 (gmt 0)

hi,

ok i guess ill go for the simple 404 then...

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
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