.htaccess rewrite www to non-www and remove .html
- by lester8891
I need rewrite rules to redirect the following:
http://www. to http://
/file.html to /file
I've tried using a combination of these but each time it results in a redirect loop on one of the situations
RewriteBase /
RewriteRule ^(.*)\.html$ $1 [NC]
RewriteCond %{HTTP_HOST} ^www.domain.co.uk [NC, L]
RewriteRule ^(.*)$ http://domain.co.uk/$1…