From: Luca Toscano
Date: Fri, 19 Feb 2016 07:51:45 +0000 (+0000)
Subject: Improved sections.html after Eric's feedback.
X-Git-Tag: 2.5.0-alpha~2041
X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ca8408de6243fa7f84bba140ffe7f24e984aaa31;p=thirdparty%2Fapache%2Fhttpd.git
Improved sections.html after Eric's feedback.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1731192 13f79535-47bb-0310-9956-ffa450edef68
---
diff --git a/docs/manual/sections.xml b/docs/manual/sections.xml
index cee3d5c0b55..4463ae51f3b 100644
--- a/docs/manual/sections.xml
+++ b/docs/manual/sections.xml
@@ -536,36 +536,35 @@ are interpreted, it is important to understand how this works.
of the httpd to determine how they should act.
An example can help to visualize the whole process. The following configuration uses the
Header directive of mod_headers to set
- a specific HTTP header. What value will httpd set in the foo header for a request to
+ a specific HTTP header. What value will httpd set in the CustomHeaderName header for a request to
/example/index.html ?
<Directory "/">
- Header set foo one
+ Header set CustomHeaderName one
<FilesMatch ".*">
- Header set foo three
+ Header set CustomHeaderName three
</FilesMatch>
</Directory>
<Directory "/example">
- Header set foo two
+ Header set CustomHeaderName two
</Directory>
- - Directory "/" matches and an initial configuration to set the "foo" header with the value "one" is created.
- - Directory "/example" matches, and since mod_headers specifies in its code to override in case of a merge, a new configuration is created to set the "foo" header with the value "two".
- - FilesMatch ".*" matches and another merge opportunity arises, causing the "foo" header
- to be set with the value "three".
- - Eventually during the next steps of the HTTP request processing mod_headers will be called and it will receive the configuration to set the "foo" header with the value "three". mod_headers normally uses this configuration to perfom its job, namely setting the foo header. This does not mean that a module can't perform a more complex action like discarding directives because not needed or deprecated, etc..
+ - Directory "/" matches and an initial configuration to set the
CustomHeaderName header with the value one is created.
+ - Directory "/example" matches, and since mod_headers specifies in its code to override in case of a merge, a new configuration is created to set the
CustomHeaderName header with the value two.
+ - FilesMatch ".*" matches and another merge opportunity arises, causing the
CustomHeaderName header to be set with the value three.
+ - Eventually during the next steps of the HTTP request processing mod_headers will be called and it will receive the configuration to set the
CustomHeaderName header with the value three. mod_headers normally uses this configuration to perfom its job, namely setting the foo header. This does not mean that a module can't perform a more complex action like discarding directives because not needed or deprecated, etc..
This is true for .htaccess too since they have the same priority as Directory in the merge order. The important concept to understand is that configuration sections like Directory and FilesMatch are not comparable to module specific directives like Header or RewriteRule because they operate on different levels.
-Some useful merge examples to practice
+Some useful examples
Below is an artificial example to show the order of
merging. Assuming they all apply to the request, the directives in