error_page directive, how does context affect error handling behavior?
mdounin at mdounin.ru
Mon Feb 27 15:03:12 UTC 2012
On Mon, Feb 27, 2012 at 03:19:38PM +0100, Grégory Pakosz wrote:
> > The error_page directives are inherited if and only if there is absolutely
> > NO error_page directive on the current level. Moreover, whenever you use
> > the error_page directive you are doing two things: 1) explicitly setting
> > error pages for the specified error codes 2) implicitly resetting error
> > pages for all the other error codes that are not explicitly set on the
> > current level to their default values So your "error_page 418
> > http://nginx.org;" directive not only set the error page for error code
> > 418, but also reset the error pages for error code 404 and all the other
> > error codes to their default values. Max
> > Hi Max,
> Thank you for your answer. May I suggest that explanation enters the wiki
> in the error_page directive section?
: These directives are inherited from the previous level if and
: only if there are no error_page directives on the current level.
More information about the nginx