views:

11

answers:

1

Hi!

I´m trying to do a 301 redirect in a htacess file. I want to point all pages on one domain to one single page on another domain and I do not want to manually redirect all single pages.

Ex: www.olddomain.com/1.html and www.olddomain.com/2.html should both point to www.newdomain.com.

Hope anyone could help me.

A: 
RewriteCond %{HTTP_HOST} .*olddomain\.com$
RewriteRule ^ http://www.newdomain.com/one-single-page.html [L,R=301]
toscho
Hmm, it doesn´t seem to have any effect at all.
Jonas
Do you have a RewriteLog? Therein you should find the reason.
toscho