-
Notifications
You must be signed in to change notification settings - Fork 50
/
.htaccess
executable file
·60 lines (54 loc) · 2 KB
/
.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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
AddDefaultCharset utf-8
<IfModule mod_rewrite.c>
RewriteEngine On
# all requests pass through index.php first
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule . index.php [L]
# access files without .php extension except for wordpress blog
RewriteRule ^(blog|wp-admin)($|/) - [L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule .* $0.php
</IfModule>
# All Error Documents should be a single file
ErrorDocument 403 /inc/errorPage.php
ErrorDocument 404 /inc/errorPage.php
ErrorDocument 405 /inc/errorPage.php
ErrorDocument 408 /inc/errorPage.php
ErrorDocument 410 /inc/errorPage.php
ErrorDocument 411 /inc/errorPage.php
ErrorDocument 412 /inc/errorPage.php
ErrorDocument 413 /inc/errorPage.php
ErrorDocument 414 /inc/errorPage.php
ErrorDocument 415 /inc/errorPage.php
ErrorDocument 500 /inc/errorPage.php
ErrorDocument 501 /inc/errorPage.php
ErrorDocument 502 /inc/errorPage.php
ErrorDocument 503 /inc/errorPage.php
ErrorDocument 506 /inc/errorPage.php
# If Directory is requested, give index.php of it if there is one, else give the error document page
DirectoryIndex index.php /inc/errorPage.php
#Gzip - compress text, html, javascript, css, xml
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE text/plain
AddOutputFilterByType DEFLATE text/html
AddOutputFilterByType DEFLATE text/xml
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE application/xml
AddOutputFilterByType DEFLATE application/xhtml+xml
AddOutputFilterByType DEFLATE application/rss+xml
AddOutputFilterByType DEFLATE application/javascript
AddOutputFilterByType DEFLATE application/x-javascript
</IfModule>
#End Gzip
<ifModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk Yes
mod_gzip_item_include file .(html?|txt|css|js|php|pl)$
mod_gzip_item_include handler ^cgi-script$
mod_gzip_item_include mime ^text/.*
mod_gzip_item_include mime ^application/x-javascript.*
mod_gzip_item_exclude mime ^image/.*
mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
</ifModule>
SetEnv TZ EST