18 messages in ru.sysoev.nginxRe: Possible rewrite regular expressi...
FromSent OnAttachments
Peter HoangJun 23, 2008 2:33 am 
RoxisJun 23, 2008 2:44 am 
Peter HoangJun 23, 2008 6:01 am 
Peter HoangJun 23, 2008 7:43 am 
Igor SysoevJun 23, 2008 7:55 am 
RoxisJun 23, 2008 7:56 am 
Peter HoangJun 23, 2008 8:01 am 
Peter HoangJun 24, 2008 8:47 am 
Igor SysoevJun 24, 2008 8:54 am 
Peter HoangJun 24, 2008 9:03 am 
Peter HoangJun 24, 2008 9:43 am 
Igor SysoevJun 24, 2008 11:01 am 
Igor SysoevJun 24, 2008 11:02 am 
Peter HoangJun 24, 2008 6:09 pm 
Peter HoangJun 24, 2008 10:01 pm 
Peter HoangJun 25, 2008 1:12 am 
Peter HoangJun 25, 2008 11:56 am 
Michal MachJul 23, 2009 4:13 am 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Re: Possible rewrite regular expression bug?Actions...
From:Peter Hoang (list@public.gmane.org)
Date:Jun 24, 2008 6:09:06 pm
List:ru.sysoev.nginx

Hi Igor,

I have a search form on the site and sometimes people do searches for "C++". When they submit the form, the URL will be http://localhost/search?q=C%2B%2B because the browser will encode the term "C++". Since we want to make it search engine friendly, we redirect user to http://localhost/search/q-C%2B%2B.html, hence my question.

Any suggestion?

Cheers,

Cuong

Igor Sysoev wrote:

On Tue, Jun 24, 2008 at 06:03:51PM +0200, Peter Hoang wrote:

url would be http://localhost/cms/q-%2B%2B.html. Is there a way to prevent this from happening? Thanks.

It had been implemented long ago in 0.3.10:

*) Bugfix: the "rewrite" directive did not unescape URI part in redirect, now it is unescaped except the %00-%25 and %7F-%FF characters.

Why do you need "c%2B%2B" in URL ? "c++" is valid unambiguous URL part.