ridz4fun Posted May 7, 2008 Share Posted May 7, 2008 Hey Everyone!! I’m really, really new to Apache and am hoping someone knows the answer to this one. Ok, I’ve got a domain, we’ll call it domain.com. I have a new domain, we’ll call it: newdomain.com. If a user types in the domain.com or www.domain.com it works fine, the problem is if a user has domain.com/pages/contact.html bookmarked, it takes them to an Error 404 page. How do I get rid of all the stuff past the / ? RewriteEngine On RewriteCond %{HTTP_HOST} domain.com [OR] RewriteCond %{HTTP_HOST} www.domain.com RewriteRule ^(.*)$ http://www.newdomain.com/new_dir$1 [R=301,L,QSA] TIA!!! Link to comment https://forums.phpfreaks.com/topic/104599-really-easy-rewritecond-question/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.