marcinwrochna/www-app/master/.htaccess - Htaccess File

marcinwrochna/www-app/master/.htaccess

RewriteEngine on

# Pass existing files.
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^(.*)$           -                                                [last,L,NE]
# Pass doxygen.
RewriteRule ^doxygen         -                                                [last,L,NE]
# Pass some fixed files that don't exist (to standard 404 that bots can recognise)
RewriteRule ^crossdomain.xml       -                                          [last,L,NE]
RewriteRule ^sitemap.xml           -                                          [last,L,NE]

# Warning: actions can't have the same name as a directory.

# impersonate($1)/someStaticFile.js
RewriteRule ^impersonate((.+))/(.*...?)$               $2 [last,L,NE]
# impersonate($1)/$2($3)
RewriteRule ^impersonate((.+))/(.+)((.*))$            index.php?impersonate=$1&action=$2&args=$3&%{QUERY_STRING} [last,L,NE]
# impersonate($1)/$2
RewriteRule ^impersonate((.+))/(.+)$                    index.php?impersonate=$1&action=$2&%{QUERY_STRING}         [last,L,NE]
# impersonate($1)[/]
RewriteRule ^impersonate((.+))/?$                       index.php?impersonate=$1&%{QUERY_STRING}                   [last,L,NE]
# $2($3)
RewriteRule ^(.+)((.*))$                                index.php?action=$1&args=$2&%{QUERY_STRING}                [last,L,NE]
# $2($3 - some email clients cut the confirmRegistration(key) link
RewriteRule ^(.+)((.*)$                                  index.php?action=$1&args=$2&%{QUERY_STRING}                [last,L,NE]
# $2
RewriteRule ^(.+)$                                        index.php?action=$1&%{QUERY_STRING}                        [last,L,NE]

On Github License

Files

Download PDF of Htaccess file
QUERY_STRING, REQUEST_FILENAME

Comments

Apache