40 lines
1.2 KiB
ApacheConf
40 lines
1.2 KiB
ApacheConf
RewriteEngine On
|
|
RewriteBase /
|
|
Options +FollowSymlinks
|
|
Options -Indexes
|
|
|
|
RewriteCond %{HTTP_HOST} ^www\.(.*)$ [NC]
|
|
RewriteRule ^(.*)$ https://%1/$1 [R=301,L]
|
|
RewriteCond %{SERVER_PORT} !=443
|
|
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=permanent]
|
|
|
|
ErrorDocument 404 /404.html
|
|
|
|
RewriteCond %{REQUEST_URI} !^(.*)/libraries/(.*) [NC]
|
|
RewriteCond %{REQUEST_URI} !^(.*)/css/(.*) [NC]
|
|
RewriteRule ^admin/([^/]*)/([^/]*)/(.*)$ admin/index.php?module=$1&action=$2&$3 [L]
|
|
|
|
|
|
|
|
RewriteRule ^admin/$ admin/index.php [L]
|
|
RewriteRule ^wyszukiwarka$ index.php?search=true&lang=pl [L]
|
|
RewriteRule ^wersja-tymczasowa$ index.php?devel=true&lang=pl [L]
|
|
|
|
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index.php
|
|
RewriteRule ^ /%1 [R=301,L]
|
|
|
|
<Files *.conf>
|
|
Order Deny,Allow
|
|
Deny from all
|
|
</Files>
|
|
<Files *.log>
|
|
Order Deny,Allow
|
|
Deny from all
|
|
</Files>
|
|
RewriteCond %{HTTP_HOST} ^(www\.)?kontrans.pagedev.pl$
|
|
RewriteRule ^pl/$ index.php?a=change_language&id=pl [L]
|
|
|
|
RewriteRule ^newsletter/signin/$ index.php?module=newsletter&action=signin [L]
|
|
RewriteRule ^newsletter/confirm/hash=(.*)$ index.php?module=newsletter&action=confirm&hash=$1 [L]
|
|
RewriteRule ^newsletter/unsubscribe/hash=(.*)$ index.php?module=newsletter&action=unsubscribe&hash=$1 [L]
|