Hi all,
I’ve been messing around with this .htaccess trick for about an hour now, and I can’t seem to get anything to happen. I tried the examples from both Ken and cyclone.
I go into my Control Panel, and then I go to the Website Files and Scripts section where I can edit the .htaccess file. I have two options: Add Rule, or Edit Manually. I selected Edit Manually so I could just copy and paste the code into the text box.
I pasted the code, changed the dummy URLs to my own URL, and then saved the file.
Now when I go and type my url in the address bar without the www, I expect it to redirect to the www version, but it doesn’t. Isn’t that what it’s supposed to do?
Any ideas on what I’m doing wrong here? Do I need to stop and restart the server or something?
Here are the exact two methods I tried:
[HTML]
RewriteEngine on
RewriteCond %{HTTP_HOST} !^onlinepokercraze.com [NC]
RewriteCond %{HTTP_HOST} !^$
RewriteRule ^/(.*) http://www.onlinepokercraze.com/$1 [R=301,L]
RewriteCond %{HTTP_HOST} ^onlinepokercraze.com$ [NC]
RewriteRule ^(.*)$ http://www.onlinepokercraze.com/$1 [R=301,L][/HTML]Thanks guys.