Forum Moderators: phranque
[edited by: phranque at 10:35 pm (utc) on Feb 24, 2014]
[edit reason] disabled graphic smileys [/edit]
[edited by: g1smd at 10:28 pm (utc) on Feb 24, 2014]
I need to rewrite the URL to look like this:
[sub.domain.com...]
Why? Wouldn't it be simpler to have a normal query with ampersand in the middle, and let the php sort it out?
If it has to be a question mark, you can't use QSA. You'd have to
:: detour to test site, because something very similar came up recently ::
RewriteCond %{QUERY_STRING} !^o=
RewriteCond %{QUERY_STRING} (.+)
RewriteRule (.*) http://www.example.com/pagename.php?o=$1?%1 [R=301,L,NE]
You do not want to do this. The first condition is to prevent an infinite loop. The last condition-- which has to be last-- is the one you're capturing from.
[edited by: phranque at 8:32 pm (utc) on Feb 25, 2014]
[edit reason] disable graphic smileys [/edit]