Welcome! Log In Create A New Profile

Advanced

Re: Understanding location blocks and try files

Jonathan Matthews
January 22, 2014 02:04PM
On 22 January 2014 18:31, AD7six <nginx-forum@nginx.us> wrote:
> What confuses me is why this example is a 404:
>
>> curl -i http://nginx.dev/apples.json
>> HTTP/1.1 404 Not Found
>> Server: nginx/1.4.4
>
> As can be seen in the log [3] there is an invalid response from /index.php.
> If I disable the location block adding cache headers for json files [4]
> though, the response is fine.
>
> Can someone shed some light as to why this happens?

I was half-way through writing a response when I noticed I'd slightly
misunderstood part of what you wrote. I thought about going back and
checking what I'd missed but to be brutally honest, the horrible maze
of includes I'd had to work my way through once already put me /right/
off!

Suggestions:

1) Have a very careful read through http://nginx.org/r/location and
nginx.org/r/try_files.

2) Simplify your problem so you can present it inline to the list,
without external links and without *all* those includes! You'll get
significantly more interest in your problem that way, and may actually
discover the solution yourself ;-)

Cheers,
Jonathan

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Understanding location blocks and try files

AD7six January 22, 2014 01:31PM

Re: Understanding location blocks and try files

Jonathan Matthews January 22, 2014 02:04PM

Re: Understanding location blocks and try files

AD7six January 22, 2014 02:54PM

Re: Understanding location blocks and try files

Francis Daly January 22, 2014 03:38PM

Re: Understanding location blocks and try files

Jonathan Matthews January 22, 2014 04:08PM

Re: Understanding location blocks and try files

Valentin V. Bartenev January 22, 2014 04:32PM

Re: Understanding location blocks and try files

Francis Daly January 22, 2014 05:20PM

Re: Understanding location blocks and try files

AD7six January 23, 2014 06:54AM

Re: Understanding location blocks and try files

Francis Daly January 23, 2014 08:44PM

Re: Understanding location blocks and try files

AD7six January 24, 2014 11:17AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 165
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready