Variable should stay the same, I only want a 301 permanent redirection from domain to subdomains just for that specific category.
Hope someone will help
asahmed
8:26 pm on Aug 26, 2010 (gmt 0)
someone help please
jdMorgan
8:40 pm on Aug 26, 2010 (gmt 0)
Try searching this forum for that type of code -- It's been posted many times, including once already today [webmasterworld.com]. modify it to suit your needs, test it, and then ask any specific questions back here.
Please see our Apache Forum Charter for additional information.
Thanks, Jim
asahmed
9:01 pm on Aug 26, 2010 (gmt 0)
Thanks Jim,
I'm sorry I don't really understand this, I've searched but didn't get a solution..
but the redirection is only done when the product id is '1' and it redirects to product '1%3f'
what I want is to pass a variable, i mean any numeric value should be redirected with the same value.
Hope you can help
Thanks
g1smd
9:16 pm on Aug 26, 2010 (gmt 0)
The %3f will be the stray question mark your rule adds on the end. It's there in your code.
In place of the '1' in the RewriteCond, use ([0-9]+) and then reference it using the %1 backreference in the rule target, in place of the hard-coded '1'.
This gets rid of the unnecessary "/index.php" in the sub.domain.com URLs, keeping only the query string (which passes through the above rule unchanged).