RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} !^domain\.com$ [NC]
RewriteRule ^(.*)$ http://domain.com/$1 [R=301,L]
Lackay! said:The best way to correct any issues from the whole "www" or "non-www" is to add the following to your .htaccess:
Code:RewriteEngine On RewriteBase / RewriteCond %{HTTP_HOST} !^domain\.com$ [NC] RewriteRule ^(.*)$ http://domain.com/$1 [R=301,L]
Since 2007, Forum Promotion has specialized in providing advertising solutions to webmasters looking to promote their communities. We pride ourselves in being the bridge that connects forum administrators, bloggers, and more.
We use essential cookies to make this site work, and optional cookies to enhance your experience.