views:

66

answers:

1

Hey all,

I have the following rule:

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico 
RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]

and my url is as follows:

http://www.mydomain.com/189-9544737-0616922?%5Fencoding=UTF8&node=10

On myphp.php

var_dump($_GET): array(3) { 
  ["q"]=>  string(19) "185-8676848-3133633" 
  ["_encoding"]=>  string(4) "UTF8" 
  ["node"]=>  string(2) "10" }

Any ideas?

regards,

A: 

Try adding a B modifier:

Apache has to unescape URLs before mapping them, so backreferences will be unescaped at the time they are applied. Using the B flag, non-alphanumeric characters in backreferences will be escaped.

RewriteRule ^(.*)$ index.php?q=$1 [B,L,QSA]
Sean Bright
It seems like nothing is change...
maozet
What do you want to see on the PHP side? The entire URL and query string in a single variable?
Sean Bright