denniemark
05-10-2012, 03:51 AM
Hi all,
Actually, I want to redirect own old domain to new domain via .htaccess file.
I wrote this code in .htaccess file.
Options +FollowSymLinks
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} !^OLDDOMAIN\.com$ [NC]
RewriteRule ^(.*)$ http://NEWDOMAIN.com [R=301,L]
But old domain is not redirected on new domain. I am using Linux server.
Is there any error in this code? Please suggest. Any help is greatly appreciated!
Actually, I want to redirect own old domain to new domain via .htaccess file.
I wrote this code in .htaccess file.
Options +FollowSymLinks
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} !^OLDDOMAIN\.com$ [NC]
RewriteRule ^(.*)$ http://NEWDOMAIN.com [R=301,L]
But old domain is not redirected on new domain. I am using Linux server.
Is there any error in this code? Please suggest. Any help is greatly appreciated!