I want to remove www. from my site url. I have added this to .htaccess:
RewriteCond %{HTTP_HOST} ^www.mydomain.com$ [NC]
RewriteRule ^(.*)$ http://mydomain.com/$1 [R=301,L]
It works if I type www.domain.com/x but not if I type www.domain.com/x/y. The rewrite "eats" the x value.
Thanks for your help.