Hi, I'm working on a clients website at the moment, I've just ported it all over from ASP to PHP. How can I redirect all requests for a .asp page to .php? For example, site.com/about.asp would go to site.com/about.php As well as this, the site is also working under .com and .co.uk I need to redirect asp to php and any requests for .co.uk to go to .com e.g: site.co.uk/about.asp would go to site.com/about.php site.com/about.asp would go to site.com/about.php site.co.uk would go to site.com Regards, Ryan
RewriteEngine On RewriteRule ^(.*).asp$ $1.php [R=301,L] that should redirect all asp to php Edit Second part would be RewriteEngine on RewriteCond %{HTTP_HOST} ^(.*)yourdomain.co.uk [NC] RewriteRule ^(.*)$ http://yourdomain.com/$1 [R=301,L]