Forum Moderators: phranque
RewriteCond %{HTTP_HOST} !^fully\.qualified\.domain\.name [NC]
RewriteCond %{HTTP_HOST} !^$
RewriteRule ^/(.*) [fully.qualified.domain.name...] [L,R]
Thinking this would be a good way to get my feet wet I took the example and changed it to what I thought it was meant to be so I did
RewriteCond %{HTTP_HOST} !^example\.com [NC]
RewriteCond %{HTTP_HOST} !^$
RewriteRule ^/(.*) http://www.example.com/$1 [L,R]
Loaded into my htacess file went to http://example.com and nothing happened. I was not redirected to http://www.example.com (of course using my domain instead of example.com)
Yes I started with:
Options +FollowSymLinks
RewriteEngine on
What did I do wrong?
For more information, see the documents cited in our forum charter [webmasterworld.com] and the tutorials in the Apache forum section of the WebmasterWorld library [webmasterworld.com].
Jim