Forum Moderators: phranque
servername.com/profile/john/phone to servername.com/profile.html?member=john§ion=phone
using
RewriteRule ^profile/(.*)/(.*)$ profile.html?member=$1§ion=$2 [L]
Now, the problem comes when the user logs in and tries to get
servername.com/profile/john/phone?Username=aaa&SessionID=bbb&Option=ccc
to servername.com/profile.html?member=john§ion=phone&Username=aaa&SessionID=bbb&Option=ccc
using
RewriteRule ^profile/(.*)/(.*)\?(.*)$ profile.html?member=$1§ion=$2\&$3
The "?Username=aaa&SessionID=bbb&Option=ccc" are not passed to the profile.html PHP script at all. I have echo'd $QUERY_STRING from the profile.html scipt and only "member=john§ion=phone" comes through.
There could be any number of variables after the? and in any order, so I was hoping that the third (.*) and "\&$3" would simply append the whole string to the re-written URL no matter what's in it.
What am I doing wrong here?