Beginner's question: redirecting /dir/index.html to /dir/

ez77 nginx-forum at nginx.us
Sun Sep 12 20:13:11 MSD 2010


> rewrite ^(.*/)index.html http://$host$1 permanent;

Hi Mat,

I like your proposal better, which looks more elegant without the if
clause, but I don't know where to include it. Under location / I get a
redirect loop.

Thanks,

Ezequiel

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,128951,129754#msg-129754




More information about the nginx mailing list