Hi guys, I know that I need to redirect either the www or http version of my site to the other version. How do I go about this? (I know it's a stupid question, but I've been neglecting this for ages so I thought I might as well ask.)
if you use Apache, and are able to use mod_rewrite, you can do the redirect using a .htaccess file. This example will redirect http://example.com to http://www.example.com , and any subsequent pages as well. Create a file at the root of your website named ".htaccess" and place the following contents in it: RewriteEngine on rewritecond %{http_host} ^example.com [nc] rewriterule ^(.*)$ http://www.example.com/$1 [r=301,nc]