On Sun, Feb 13, 2011 at 11:27 PM, agentzh <agentzh@gmail.com> wrote:
>
> You see, how tricky it is behind the scene! No wonder people keep
> saying "nginx's if is evil".
I very much see why "if is evil", but unfortunately there seems to be
almost no alternative if you want to take some action based on things
in headers or other variables.
So what is a generally safe way to handle control flow where the
conditions are based on something that is not in the URI (making
rewrite useless)?
Note that changing the back-end application to handle things is often
not possible when using commercial web applications behind nginx.
I guess this sort of thing could always be a job for a general-purpose
web server like Apache. Nginx is meant to be simple and lightweight;
perhaps the general design is at odds with complex flow control.
--
RPM
_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx