![]() | | ||||||||
| | #1 |
| Elite Warrior Join Date: Oct 2009 Location: New York, NY U.S.A.
Posts: 348
Thanks: 39
Thanked 0 Times in 0 Posts
|
Where in the .htaccess file (top, bottom, or center) does the piece of code go to 301 redirect a URL? For example, a non-www to a www URL?
|
| | |
| | #2 |
| ɹoıɹɹɐʍ ǝʌıʇɔɐɹǝdʎɥ War Room Member Join Date: Dec 2008 Location: Texas
Posts: 258
Thanks: 55
Thanked 25 Times in 23 Posts
|
Try this before anything else: Code: RewriteEngine On
RewriteCond %{HTTP_HOST} www.yoursite.com
RewriteRule ^(.*) http://yoursite.com/$1 [L,R=301] |
|
Robin | |
| | |
![]() |
|
| Tags |
| file, htaccess |
| Thread Tools | |
| |
![]() |