Update: Problem was with my id generating page. Sorry.
Hi,
I have a strange problem with my mod_rewrite rules. I have a page that generates 32 character random session ids and uses them to redirect user to an url like this:
http://www.mysite.com/RANDOMSESSIONID/m ... hp?a=1&b=2
This url should be written to:
http://www.mysite.com/mypage.php?a=1&b= ... MSESSIONID
I have the following rule to accomplish this:
RewriteRule ([A-Z0-9]{32})/(.*) $2?$1 [L,NE,QSA]
But when the url is written, only the part before the "&" in the query string is used. So the url is written to:
http://www.mysite.com/mypage.php?a=1&se ... MSESSIONID
I have also tried only redirecting to the page using the query string like this to see what is going on:
RewriteRule ([A-Z0-9]{32})/(.*) $2?%{QUERY_STRING} [L,NE]
And this was the result:
http://www.mysite.com/mypage.php?a=1
Am I missing something here? Shouldn't %{QUERY_STRING} refer to a=1&b=2 ?