ayoub
ayoub

Reputation: 1

Domain Name Redirection with Path?

I need your Help please! I have a domain name that redirected to an other:

www.xxx.com ===> redirected to ===> www.yyy.com

If i write www.xxx.com/photo.html, i want to be redirected to www.yyy.com/photo.html.

It's possibl ?

Upvotes: 0

Views: 99

Answers (2)

AccuWebHosting.Com
AccuWebHosting.Com

Reputation: 1159

If you want all pages of one domain to be redirected to other domain, following .htaccess code will redirects everything after the domain name on the url to the exact same copy on the new domain url:

RewriteEngine on 
RewriteRule ^(.*)$ http://www.newdomain.com/$1 [R=301,L]

Upvotes: 0

Rick Buford
Rick Buford

Reputation: 629

Referring to previous answer to help illuminate the options. Please feel free to ask any additional questions after reading that.

Upvotes: 1

Related Questions