Index fallback?
Edho Arief
me at myconan.net
Mon Oct 10 06:25:49 UTC 2016
Hi,
On Mon, Oct 10, 2016, at 15:23, Francis Daly wrote:
> On Mon, Oct 10, 2016 at 12:56:57PM +0900, Edho Arief wrote:
>
> Hi there,
>
> untested, but...
>
> > accessing:
> > 1. site.com/a -> redirect to site.com/a/ -> show /a/index.html
> > 2. site.com/b -> redirect to site.com/b/ -> show @fallback
>
> > As a side note,
> >
> > error_page 404 = @fallback;
> >
> > Wouldn't work because as mentioned in the previous one, it returns 403
> > for #2 (directory exists, no index), not 404.
>
> Would "error_page 403" Do The Right Thing?
>
> (It may be that it matches more than you want it to, of course.)
>
Yeah, it matches a bit too much.
More information about the nginx
mailing list