Dot HTAccesser

.htaccess file generator

Mit Hilfe einer .htaccess Datei lässt sich nicht nur ein Passwortschutz realisieren, viele Apache Direktiven lassen sich zur Laufzeit beeinflussen. Der htaccesser bietet dafür eine Hilfestellung.

Nicht alle Einstellungen zeigen auf allen Apache Servern eine Wirkung. Die Konfiguration von ModRewrite z.B. muss vom Provider in der Apache-Config explizit erlaubt werden. Erlaubt der Provider einige der Einstellungen via .htaccess nicht, passiert im besten Fall gar nichts, im schlimmsten Fall gibt der Webserver einen Error 500 aus. In solch einem Fall löscht man ganz einfach die .htaccess Datei wieder und alles sollte wieder beim alten sein.

Default Page

What page to load if the user doesn't specify any (usually index.html or index.php)
Can specify multiple in a list (ie index.php index.html index.htm default.htm)


Execution of CGI scripts using mod_cgi is permitted.

File Extensions

Server-side includes provided by mod_include are permitted.

Symbolic Links

The server will follow symbolic links in this directory.

The server will only follow symbolic links for which the target file or directory is owned by the same user id as the link.


If a URL which maps to a directory is requested, and there is no DirectoryIndex (e.g., index.html) in that directory, then mod_autoindex will return a formatted listing of the directory.


Content negotiated "MultiViews" are allowed using mod_negotiation.


Force HTTP requests to redirect HTTPS


Additional Mime Types

File extension to mime type mappings are in this format
mime/type ext
for example
text/html html
application/x-gzip gz

Protect System Files

File Cache Control

How often will the client/proxy refresh the file

Expire all clients/proxies at the same time

Protect Media Files

Check the referrer domain for images, music, and sound files

Block E-mail Harvesters

Deny access to e-mail harvesting programs.

Time-Dependant Page

Serve pages depending on time of day

Virtual DNS to Folder

Rewrite Virtual Subdomains to subfolders. Ie: rewrite to Useful for virtual user domains.

Redirect Failing URLs To Other Webserver

When a URL is invalid, or would produce an error, redirect to a secondary server.

Rewrite Condition
Rewrite Page Page requested in the URL
Browser Dependant Page Page to use for Netscape
Page to use for IE
Page to use for text mode
Page to use for other browsers
Country Specific Page

Requires the mod_geoip is setup and configured on your server. Thought the software is free, the datafiles are a commercial product. Allows you to redirect users to specific pages depending on their country of origin.

US = United States GB = United Kingdom CA = Canada MX = Mexico FR = France NL = Netherlands A1 = Anonymous

page to redirect visitors from the country ( or

Map Folder To Script

This trick will make it possible to run a script that has parameters in the URL. You can make a custom home page script for your users that they can access like /login/home.html or /login/preferences.html and have them both go to login.php.

Folder you will reference in your href and urls (ie login)

Script that will be ran (ie login.php, login.cgi, or If you would like the rest of the path as a POST variable, do something like "login.php?page="

Custom Error Documents

Allows you to specify custom documents to serve on error conditions

Bad Request
Authentication Required
Not Found
Server Error

Use this option if a document has been moved to a new url. It will take care of automatic redirection for the user.