Simple Rewrite Question

Alan Williamson alan at aw20.co.uk
Fri Jan 16 13:52:32 MSK 2009


Morning all.

I have a very simple request to clean up

I basically need to catch URI's that end with "/" and if they do, append
index.htm to them.   The upstream proxy doesn't like to see "/".

so a request:

 http://xyz/

would be rewritten to:

 http://xyz/index.htm

and so on ...

 http://xyz/mytest/ -> http://xyz/mytest/index.htm

BUT http://xyz/mytest is to be untouched!  Only if it has a / at the end.
I want to proxy_pass these to the backend.  I am struggling to get this
right, so any pointers/help would be appreciated

thanks


-- 
http://alan.blog-city.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://nginx.org/pipermail/nginx/attachments/20090116/282f3d64/attachment.html>


More information about the nginx mailing list