On 18 July 2014 11:11, Johnathon Tinsley <johnat...@positive-internet.com>
wrote:

> To be specific:
>
> RewriteEngine on
> RewriteCond %{HTTP_HOST} !^www\.example\.com [NC]
> RewriteRule ^(.*)$ http://example.co.uk$1 [R=301,L]
>
> I've typed that enough times I don't really have to think about it anymore
> ;)


Thanks Tony & Johnathon.

I had tried mod_rewrite but clearly got my rules messed up previously.

Just to correct what Johnathon wrote, I think the last line should be:
    RewriteRule ^(.*)$ http://www.example.com/$1 [R=301,L]

Really appreciated; that's been on my list of jobs for a while!
-- 

Mark Rogers // More Solutions Ltd (Peterborough Office) // 0844 251 1450
Registered in England (0456 0902) @ 13 Clarke Rd, Milton Keynes, MK1 1LG
_______________________________________________
Peterboro mailing list
Peterboro@mailman.lug.org.uk
https://mailman.lug.org.uk/mailman/listinfo/peterboro

Reply via email to