Intro to Apache - ApacheCon
.htaccess files
  • Per-directory configuration file

  • Name of the file can be altered with the AccessFileName directive

  • The directives you are allowed to put in the file are controlled by the AllowOverride directive.

    
         None:       Forbids any directives being honored. .htaccess files 
                     are completely ignored
         AuthConfig: Allow use of the authorization directives 
         FileInfo:   Allow use of the directives controlling document types
         Indexes:    Allow use of the directives controlling directory indexing
         Limit:      Allow use of the directives controlling host access
         Options:    Allow use of the directives controlling specific 
                     directory features
         All:        All of the above
    
      

  • For example:

    
        AllowOverride AuthConfig Indexes
    
      

  • A very common use is authentication. More on this a little later.

  • For the most part, .htaccess files are for people that don't have access to the main server configuration file.

Index
Back to 3 config files
Forward to .htaccess files: Dispelling the myth

ApacheCon : Intro to Apache - Slide #59 of 139