Gillbot
Lifer
I've tried using the Mod Rewrite to direct all traffic from my old domain to the new and I can't seem to get it working right.
My current list in my htaccess file is a mile long, I'd like to simplify it.
Redirect Permanent /bb http://www.example.com/bb
Redirect Permanent /BB http://www.example.com/bb
Redirect Permanent /sponsor.html http://www.example.com/sponsor.html
Redirect Permanent /Sponsor.html http://www.example.com/sponsor.html
Redirect Permanent /sponsor.htm http://www.example.com/sponsor.html
Redirect Permanent /Sponsor.htm http://www.example.com/sponsor.html
The above is just an example, the actual list is many lines long. My old host was NOT case sensitive but the new one is. Rather than going through every page, making them all lower case and messing up with all of my referral links, I'm looking for a way to redirect more easily. (Yes, I know I should have started that from the beginning but i'm a n00b! I have been updating everything from here on though.)
To further complicate this my old host had a few subdomains as well, I'd like to redirect all of those to the new main page.
for example:
forums.olddomain.com is now just under www.example.com so I'd like EVERYTHING to be forwarded to the new home page. That way those referral links are not really lost.
I'd like to do something like this: *.olddomain.com/* redirects to www.example.com so any page from any subdomain gets directed to the new home page.
Now I tried this:
RewriteEngine ON
RewriteRule ^(.*)$ http://example.com/$1 [R=301,L]
But it did not work. I don't understand the syntax so I may have it setup incorrectly but any request for olddomain.com went nowhere except to a 404 page.
My current list in my htaccess file is a mile long, I'd like to simplify it.
Redirect Permanent /bb http://www.example.com/bb
Redirect Permanent /BB http://www.example.com/bb
Redirect Permanent /sponsor.html http://www.example.com/sponsor.html
Redirect Permanent /Sponsor.html http://www.example.com/sponsor.html
Redirect Permanent /sponsor.htm http://www.example.com/sponsor.html
Redirect Permanent /Sponsor.htm http://www.example.com/sponsor.html
The above is just an example, the actual list is many lines long. My old host was NOT case sensitive but the new one is. Rather than going through every page, making them all lower case and messing up with all of my referral links, I'm looking for a way to redirect more easily. (Yes, I know I should have started that from the beginning but i'm a n00b! I have been updating everything from here on though.)
To further complicate this my old host had a few subdomains as well, I'd like to redirect all of those to the new main page.
for example:
forums.olddomain.com is now just under www.example.com so I'd like EVERYTHING to be forwarded to the new home page. That way those referral links are not really lost.
I'd like to do something like this: *.olddomain.com/* redirects to www.example.com so any page from any subdomain gets directed to the new home page.
Now I tried this:
RewriteEngine ON
RewriteRule ^(.*)$ http://example.com/$1 [R=301,L]
But it did not work. I don't understand the syntax so I may have it setup incorrectly but any request for olddomain.com went nowhere except to a 404 page.