Strange rewrite_by_lua outcome

Tim Mensch tim-nginx at bitgems.com
Mon Oct 17 17:45:26 UTC 2011


On 10/17/2011 10:33 AM, Nginx User wrote:
> Let me get this right. Do I need to always escape the "\" inserted
> to escape "." in "\." in lua and then add another couple of "\"s?
> I.E., do I need to do "sqlpatch\\\\.php" to get "sqlpatch\.php"
> passed to the regex finally? IOW, do I basically replace each "\"
> with "\\\\"?

Yes.

> If I understand agentzh, the rewrite module handles this behind the
> scenes and allows us to use familiar syntax. Is that right?

The rewrite module apparently changes how the string is parsed in the
Nginx file, yes.

Tim
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20111017/0b5be412/attachment.html>


More information about the nginx mailing list