http status code 301 - .htaccess 301 redirect -



http status code 301 - .htaccess 301 redirect -

does know how can 301 redirect traffic 1 domain other - including same url elements after domain name - , apply same rule possible links without writing each url separately - illustration this:

http://www.olddomain.com/catalogue/category/fruits/pg/2.html

to redirect to:

http://www.newdomain.com/catalogue/category/fruits/pg/2.html

at moment have this:

rewritecond %{http_host} ^olddomain\.com$ [or] rewritecond %{http_host} ^www\.olddomain\.com$ rewriterule ^/?$ "http\:\/\/www\.newdomain\.com" [r=301,l]

but won't work next situation instance:

http://www.olddomain.com/login.html

it won't redirect new domain , maintain /login.html after.

any clues?

have tried simply:

redirect 301 / http://newdomain.com/

in root folder of olddomain.com

.htaccess http-status-code-301

Comments

Popular posts from this blog

iphone - Dismissing a UIAlertView -

c# - Can ProtoBuf-Net deserialize to a flat class? -

javascript - Change element in each JQuery tab to dynamically generated colors -