yarekGmail
asked on
.htaccess simple redirection
Hi experts,
Here is a simple .htaccess question
presidentevil
My goal is to redirect presidentevil.fr to www.presidentevil.fr
I use that:
SetEnv PHP_VER 5
RewriteEngine on
Rewritecond %{HTTP_HOST} ^presidentevil.fr$
Rewriterule ^(.*) http://www.presidentevil.fr/$1 [QSA,L,R=301]
It seems the htaccess is active because If I remove
SetEnv PHP_VER 5
I got php errors.
Troubles is : when I type in presidentevil.fr it does not redirect to www. !
What am I doing wrong ?
regards
Here is a simple .htaccess question
presidentevil
My goal is to redirect presidentevil.fr to www.presidentevil.fr
I use that:
SetEnv PHP_VER 5
RewriteEngine on
Rewritecond %{HTTP_HOST} ^presidentevil.fr$
Rewriterule ^(.*) http://www.presidentevil.fr/$1 [QSA,L,R=301]
It seems the htaccess is active because If I remove
SetEnv PHP_VER 5
I got php errors.
Troubles is : when I type in presidentevil.fr it does not redirect to www. !
What am I doing wrong ?
regards
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
For a non-generator based solution, check out http://kb.mediatemple.net/questions/85/Using+.htaccess+rewrite+rules#gs/add-www-or-https