mod_rewrite 301 redirect

To redirect the entire site, for example to enforce www. , add the following to .htaccess

Options +FollowSymLinks
RewriteEngine On
RewriteCond %{HTTP_HOST} ^domain\.com$ [NC]
RewriteRule ^(.*)$ http://www.domain.com/$1 [R=301,L]

You can leave a response, or trackback from your own site.

Leave a Reply