From: Rich Bowen Date: Thu, 25 Jul 2002 17:07:12 +0000 (+0000) Subject: Links to module, directive, and howto documentation. X-Git-Tag: 2.0.40~124 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6a96194dfa4ceb1f6e7385a0b034224d5384aad5;p=apache Links to module, directive, and howto documentation. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96188 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/docs/manual/howto/htaccess.html b/docs/manual/howto/htaccess.html index 44bcf00959..6c5ebe5869 100755 --- a/docs/manual/howto/htaccess.html +++ b/docs/manual/howto/htaccess.html @@ -69,7 +69,8 @@ directory, and all subdirectories thereof.

Note: If you want to call your .htaccess file something else, you can - change the name of the file using the AccessFileName directive. For + change the name of the file using the AccessFileName directive. For example, if you would rather call the file .config then you can put the following in your server configuration file:

@@ -84,18 +85,25 @@ contain an Override section, specifying what value must be in AllowOverride in order for that directive to be permitted.

-

For example, if you look at the docs for the AddDefaultCharset +

For example, if you look at the docs for the AddDefaultCharset directive, you will find that it is permitted in .htaccess files. (See - the Context line in the directive summary.) The Override line reads + the Context line in the directive summary.) The Override line reads "FileInfo". Thus, you must have at least "AllowOverride FileInfo" in order for this directive to be honored in .htaccess files.

Example:

-
- Context: server config, virtual host, directory, .htaccess
- Override: FileInfo -
+
+ + + + + +
+Context:server config, virtual host, directory, .htaccess
+Override:FileInfo

If you are unsure whether a particular diretive is permitted in a .htaccess file, look at the documentation for that directive, and check @@ -119,7 +127,8 @@

However, in general, use of .htaccess files should be avoided when possible. Any configuration that you would consider putting in a - .htaccess file, can just as effectively be made in a <Directory> + .htaccess file, can just as effectively be made in a <Directory> section in your main server configuration file.

There are two main reasons to avoid the use of .htaccess files.

@@ -251,8 +260,8 @@ Options Includes

Note that AllowOverride AuthConfig must be in effect for these directives to have any effect.

-

Please see the authentication tutorial for a more complete discussion - of authentication and authorization.

+

Please see the authentication tutorial + for a more complete discussion of authentication and authorization.

SSI example

@@ -270,6 +279,9 @@ Options Includes

Note that AllowOverride Options and AllowOverride FileInfo must both be in effect for these directives to have any effect.

+

Please see the SSI tutorial for a more + complete discussion of server-side includes.

+

CGI example

Finally, you may wish to use a .htaccess file to permit the execution @@ -293,13 +305,17 @@ Options Includes

Note that AllowOverride Options must be in effect for these directives to have any effect.

+

Please see the CGI tutorial for a more + complete discussion of CGI programming and configuration.

+

Troubleshooting

When you put configuration directives in a .htaccess file, and you don't get the desired effect, there are a number of things that may be going wrong.

-

Most commonly, the problem is that AllowOverride is not set such that +

Most commonly, the problem is that AllowOverride is not set such that your configuration directives are being honored. Make sure that you don't have a AllowOverride None in effect for the file scope in question. A good test for this is to put garbage in your .htaccess file and reload.