Nginx Location Matching Documentation Update

I would recommend that the documentation for location matching is
updated
http://wiki.nginx.org/HttpCoreModule#location, explicitaly the example.
It
should contain a conventional strings besides the root ‘/’ of the site:

location = / {

matches the query / only.

[ configuration A ]
}
location / {

matches any query, since all queries begin with /, but regular

expressions and any longer conventional blocks will be

matched first.

[ configuration B ]
}
location ^~ /images/ {

matches any query beginning with /images/ and halts searching,

so regular expressions will not be checked.

[ configuration C ]
}
location /media/ {

matches any query beginning with /media/ and continues serching,

so regular expressions will be checked. This will be matched only if

regular expressions don’t find a match

[ configuration D ]
}
location ~* .(gif|jpg|jpeg)$ {

matches any request ending in gif, jpg, or jpeg. However, all

requests to the /images/ directory will be handled by

Configuration C.

[ configuration E ]
}

I don’t know who could I ask about this, but I think that it’s important
that all 4 explained steps in the documentation are covered by the
example.

Posted at Nginx Forum:

On Thursday 18 October 2012 15:24:14 kustodian wrote:

I would recommend that the documentation for location matching is updated
http://wiki.nginx.org/HttpCoreModule#location, explicitaly the example.
[…]

You’re referring to the community wiki, not documentation. Feel free to
update
it yourself.

The documentation is here: nginx documentation

wbr, Valentin V. Bartenev

http://nginx.org/en/donation.html

Hello!

On Thu, Oct 18, 2012 at 04:07:50PM +0400, Valentin V. Bartenev wrote:

On Thursday 18 October 2012 15:24:14 kustodian wrote:

I would recommend that the documentation for location matching is updated
http://wiki.nginx.org/HttpCoreModule#location, explicitaly the example.
[…]

You’re referring to the community wiki, not documentation. Feel free to update
it yourself.

The documentation is here: nginx documentation

This wiki article was originated as a translation of official
documentation in Russian (which is now available in English, too,
see Module ngx_http_core_module), and I always asked people to
don’t deviate from official docs but keep it as a translation,
keeping comments/suggestions/additional notes separate from an
article.

And I actually think that suggested change will be good for
understanding, and it would be good to add it to official
documentation.

Ruslan?


Maxim D.

Sorry for a late reply and thanks for your help. I did update the wiki
documentaion http://wiki.nginx.org/HttpCoreModule#location, I hope it is
ok
and that location matching will now be clearer to new Nginx users.

Posted at Nginx Forum:

Hello!

On Sun, Oct 28, 2012 at 05:48:30PM -0400, kustodian wrote:

Sorry for a late reply and thanks for your help. I did update the wiki
documentaion http://wiki.nginx.org/HttpCoreModule#location, I hope it is ok
and that location matching will now be clearer to new Nginx users.

Ruslan already updated official docs according to your suggestion,
BTW:

http://nginx.org/r/location


Maxim D.

Maxim D. Wrote:

Ruslan already updated official docs according to your suggestion,
[email protected]
nginx Info Page

Then I will update the documentation wiki to be exactly like the
official
docs.

Posted at Nginx Forum: