Forum Moderators: phranque
I am pretty new to apache and htaccess.
I have a site which should act as two sites depending on the site id passed
A rule that redirects something like
www.test1.com/a to www.test1.com?site=1&....
www.test1.com/b to www.test1.com?site=2&....
A rule that rewrites www.abc.com & .co.in to www.test1.com/a
A rule that rewrites www.def.com & .co.in to www.test1.com/b
Any help would be greatly appreciated
Thanks :)
We can help you get your own code working here, but we can't write your code for you. Please see out Forum Charter.
Jim
This is the code that I am currently using
#RewriteCond %{HTTP_HOST} .
#RewriteCond %{HTTP_HOST} !^abc\.com [NC]
#RewriteRule (.*)$ [test1.com...] [R=301,L]
This works ok, but I get the following error
"Firefox has detected that the server is redirecting the request for this address in a way that will never complete."
Thanks in advance
RewriteCond %{HTTP_HOST} ^(www\.)?abc\.(com¦co\.in) [NC]
RewriteCond $1 !^a/
RewriteRule ^(.*)$ http://www.test1.com/a/$1 [R=301,L]
Jim