httpd-docs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joshua Slive" <jos...@slive.ca>
Subject Re: [Httpd Wiki] Update of "Recipes/QueryString" by VinkoVrsalovic
Date Wed, 30 May 2007 15:13:54 GMT
On 5/30/07, Vinko Vrsalovic <vinkovb@gmail.com> wrote:

> > >   {{{
> > > - RewriteRule ^/path/(\w+)/(\w+) /path?$1=$2
> > > + RewriteRule ^/path/([^/]+)/([^/]+) /path?$1=$2
> > >   }}}
> >
> > I don't have a particular problem with that, but it is highly unlikely
> > to work if anything outside the \w character class is in there, since
> > URL escaping in mod_rewrite is pretty messed-up on this point. There
> > was a recent message on dev@httpd about that.
> >
>
> Didn't know that... but I did a quick test:
>
>         RewriteRule /path/[^/]+ http://google.com
>
> and when accessing http://localhost/path/dsa(@@) drove me to google. So I
> think it's not *that* messed up.

The problem is extra escaping that occurs on the substitution string. So try
RewriteRule /path/([^/]+) http://google.com/?q=$1

Joshua.

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org


Mime
View raw message