views:

44

answers:

1

I have a rewrite rule

RewriteRule ^([A-Za-z0-9\/\-\_]+)+$ .?p=$1 [L]

But if I have % sign in url, it won't work. How do I modify this rule to work with percentage sign?

A: 

You can add the % to your character class ([…]). A character class specifies a group of characters that will be successful matches.

RewriteRule ^([A-Za-z0-9/_%-]+)$ .?p=$1 [L]
Daniel Vandersluis
Okei, but it seems that modrewrite is buggy, it wont go trough with %23, which is # in urlencode
Hannes