-DirectoryIndex Index.html.pl
+<IfModule mod_dir.c>
+ DirectoryIndex _NOTEXISTS
+ IndexOptions NameWidth=*
+</IfModule>
+
+Options None
+<IfModule !mod_perl.c>
+ Options +Indexes
+ # For "*.shtml" as "./project/Islet/Islet/Islet.shtml" etc.
+ Options +Includes
+ # Prevent: Options FollowSymLinks or SymLinksIfOwnerMatch is off which implies that RewriteRule directive is forbidden
+ Options +SymLinksIfOwnerMatch
+</IfModule>
-AddType text/html .shtml
AddHandler server-parsed .shtml
+AddHandler cgi-script .cgi
+
AddType "text/html; charset=us-ascii" .html
AddType "text/html; charset=us-ascii" .shtml
AddType "text/plain; charset=us-ascii" .txt
AddType "text/plain; charset=us-ascii" .asc
-Options Indexes Includes FollowSymLinks
-<FilesMatch "\.(gz|Z|bz|bz2|zip)$">
- RemoveEncoding .gz .Z .bz .bz2 .zip
- AddType application/x-gzip .gz
- AddType application/x-compress .Z
- AddType application/x-bzip .bz
- AddType application/x-bzip2 .bz2
- AddType application/zip .zip
-</FilesMatch>
-
-AddHandler cgi-script .cgi
-IndexOptions NameWidth=*
AddType application/x-rpm .rpm
AddType application/x-nokia-9000-communicator-add-on-software .aos
-<IfModule mod_php4.c>
+
+RemoveEncoding .gz .Z .bz .bz2 .zip
+AddType application/x-gzip .gz
+AddType application/x-compress .Z
+AddType application/x-bzip .bz
+AddType application/x-bzip2 .bz2
+AddType application/zip .zip
+
+<IfModule mod_php.c>
php_flag short_open_tag off
php_flag magic_quotes_gpc off
php_flag magic_quotes_runtime off
</IfModule>
-<Files "kocky">
- RewriteEngine on
- RewriteRule ^(/home/short/www/www.jankratochvil.net/)?kocky/*(.*)$ http://kocky.vellum.cz/$2 [R=301] [L]
-</Files>
-<FilesMatch "^(4c|4cinfo)$">
- RewriteEngine on
- RewriteRule ^(/home/short/www/www.jankratochvil.net/)?(4cinfo|4c)/*(.*)$ http://4c.jankratochvil.net/$3 [R=301] [L]
-</FilesMatch>
-<Files "cgi">
- RewriteEngine on
- # $1 $2$3 $4
- RewriteRule ^(/home/short/www/www.jankratochvil.net/)?cgi/viewcvs(/(.*))?([?].*)?$ http://cvs.jankratochvil.net/viewcvs/$3$4 [R=301] [L]
- RewriteRule ^(/home/short/www/www.jankratochvil.net/)?cgi/*(.*)$ http://www.jankratochvil.net/cgi-bin/$2 [R=301] [L]
-</Files>
-<Files "sw">
+<IfModule mod_rewrite.c>
+ # Do not: [R=301] [L]
+ # as any non-1st brackets' contents would get ignored!
RewriteEngine on
- RewriteRule ^(/home/short/www/www.jankratochvil.net/)?sw/*(.*)$ http://www.jankratochvil.net/project/ [R=301] [L]
-</Files>
-<Files "projects">
- RewriteEngine on
- RewriteRule ^(/home/short/www/www.jankratochvil.net/)?projects/*(.*)$ http://www.jankratochvil.net/project/$2 [R=301] [L]
-</Files>
-
-<IfDefine SSL>
- <Files "*.pl">
- RewriteEngine on
- RewriteRule ^.*?/www[.]jankratochvil[.]net/(.*)$ http://localhost:7680/$1 [P]
- </Files>
-</IfDefine>
-<IfDefine !SSL>
- Options +ExecCGI
-</IfDefine>
+ RewriteRule ^kocky(|/.*)$ http://kocky.vellum.cz/$1 [R=301,L]
+ RewriteRule ^(4cinfo|4c)(|/.*)$ http://4c.jankratochvil.net/$2 [R=301,L]
+ RewriteRule ^sw(|/.*)$ http://%{SERVER_NAME}/project$1 [R=301,L]
+ RewriteRule ^projects(|/.*)$ http://%{SERVER_NAME}/project$1 [R=301,L]
+ <IfModule !mod_perl.c>
+ RewriteRule ^(.*)[.]html[.]pl$ http://%{SERVER_NAME}/$1.pm [R=301,L]
+ RewriteRule ^(.*?)/+Index[.]pm$ http://%{SERVER_NAME}/$1/ [R=301,L]
+ RewriteCond %{REQUEST_FILENAME}/Index.pm -f
+ RewriteRule ^(.*?)/+$ http://localhost:7680/$1/Index.pm [P,L]
+ RewriteRule ^(.*[.]pm)$ http://localhost:7680/$1 [P,L]
+ </IfModule>
+</IfModule>