Redirect entire site
Options +FollowSymlinksRewriteEngine onRewriteBase /RewriteCond %{REQUEST_FILENAME} !-fRewriteCond %{REQUEST_URI} !(.+)\.(.+)RewriteCond %{REQUEST_URI} !(.*)/$RewriteRule ^(.*)$ http://www.newdomain.com/$1 [L,R=301]
Sorry, you don't have permission to post posts. Log in, or register if you haven't yet.
Comments on Redirect entire site
Forum Regular
Usergroup: Customer
Joined: Nov 27, 2006
Total Topics: 187
Total Comments: 465
I need some advice on this because although I could probably do it after a bit of experimenting, it is really important I get it right first time.
I am moving a site from adomain.co.uk to adomain.com
I have decided to start listing businesses outside the UK, so I am changing to .com
How do I do a permenant htaccess 301 redirect so that all of my pages will redirect to the new domain correctly?
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
Each page needs to redirect to the same page on the other domain? This might work, haven't tested: