-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.htaccess
31 lines (26 loc) · 940 Bytes
/
.htaccess
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
RewriteEngine on
RewriteCond %{REQUEST_METHOD} POST
RewriteRule ^ - [L]
RewriteCond %{THE_REQUEST} /([^.]+)\.php [NC]
RewriteRule ^ /%1 [NC,L,R]
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteRule ^ %{REQUEST_URI}.php [NC,L]
RewriteEngine on
RewriteCond %{THE_REQUEST} /([^.]+)\.html [NC]
RewriteRule ^ /%1 [NC,L,R]
RewriteCond %{REQUEST_FILENAME}.html -f
RewriteRule ^ %{REQUEST_URI}.html [NC,L]
RewriteRule index.html index.php
<filesMatch ".(ico|jpg|jpeg|png|gif|svg|woff2)$">
Header set Cache-Control "max-age=2592000, public"
</filesMatch>
<filesMatch ".(css|js)$">
Header set Cache-Control "max-age=86400, public"
</filesMatch>
ErrorDocument 403 /errorfile/error403.html
ErrorDocument 404 /errorfile/error404.html
ErrorDocument 500 /errorfile/error500.html
ErrorDocument 502 /errorfile/nointernet.html
ErrorDocument 503 /errorfile/nointernet.html
ErrorDocument 505 /errorfile/nointernet.html
DirectoryIndex index.html index.php