Quote:
Originally Posted by RichieBoy67
Hey all, I hope someone can help me with this..
I just removed a sub domain from a site and I want to redirect the sub domain's path to the root directory....
This is what I came up with but it doesn't seem to be working. What am I missing?
RewriteCond %{HTTP_HOST} subdomain.mysite.com
RewriteCond %{REQUEST_URI} !mysite.com/
RewriteRule ^(.*)$ mysite.com/$1 [L]
Thank you guys so much,
Rich
|
Hi Rich In .htaccess files to use the rewrite condition you need to add above it
Give that a go, but it it don't work, try the code i've done below instead, let me know mate
Code:
RewriteEngine On
RewriteCond %{HTTP_HOST} ^(www\.)?subdomain.mysite.com$ [NC]
RewriteRule ^same/(.*) http://$1.mysite.com[R=301,L]
:up: