]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Define the document root once, and then use the variable elsewhere, so
authorRich Bowen <rbowen@apache.org>
Mon, 22 Oct 2012 23:42:24 +0000 (23:42 +0000)
committerRich Bowen <rbowen@apache.org>
Mon, 22 Oct 2012 23:42:24 +0000 (23:42 +0000)
that if it gets changed one place it inherits it everywhere. Also, a
practical example of `Define` in action.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1401126 13f79535-47bb-0310-9956-ffa450edef68

docs/conf/httpd.conf.in

index 43425f8203f108fa48ea6c93852d5a4f006aade3..7a0138552db40da6311d8c5cc36b3b0d016fdf13 100644 (file)
@@ -129,8 +129,10 @@ ServerAdmin you@example.com
 # documents. By default, all requests are taken from this directory, but
 # symbolic links and aliases may be used to point to other locations.
 #
-DocumentRoot "@exp_htdocsdir@"
-<Directory "@exp_htdocsdir@">
+
+Define DOCROOT "@exp_htdocsdir@"
+DocumentRoot "${DOCROOT"}
+<Directory "${DOCROOT}">
     #
     # Possible values for the Options directive are "None", "All",
     # or any combination of: