I've just decided to switch my site on a subdomain to it's own proper domain. I therefore used the following in the .htaccess file to direct it all: RewriteEngine On RewriteCond %{HTTP_HOST} ^subdomain\.othersite\.com [nc] RewriteRule (.*) http://www.newsite.com/$1 [R=301,L] That works nicely enough, except it adds my variables I rewrote with htaccess elsewhere onto the end of the url Any ideas on how to stop this? examples: http://mms.mob453.com/view/1204.html becomes: http://www.mobmms.com/view.php/1204.html?id=1204 Thanks for any info
Are the lines RewriteCond %{HTTP_HOST} ^subdomain\.othersite\.com [nc] RewriteRule (.*) http://www.newsite.com/$1 [R=301,L] Code (markup): before all the other rewrite stuff ?
Afterwards, I just added it to the end. Should I have stuck it at the top? I'll give that a try now... edit: woohoo! Thanks for the suggestion - works fine now! I'll just go slap my hand again my forehead for a while now