forked from gea-ecobricks/ecobricks-org
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.htaccess
More file actions
261 lines (194 loc) · 7.59 KB
/
.htaccess
File metadata and controls
261 lines (194 loc) · 7.59 KB
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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
# BEGIN LSCACHE
## LITESPEED WP CACHE PLUGIN - Do not edit the contents of this block! ##
<IfModule LiteSpeed>
RewriteEngine on
CacheLookup on
RewriteRule .* - [E=Cache-Control:no-autoflush]
RewriteRule \.object-cache\.ini - [F,L]
### marker FAVICON start ###
RewriteRule favicon\.ico$ - [E=cache-control:max-age=86400]
### marker FAVICON end ###
### marker CORS start ###
<FilesMatch "\.(ttf|ttc|otf|eot|woff|woff2|font\.css)$">
<IfModule mod_headers.c>
Header set Access-Control-Allow-Origin "*"
</IfModule>
</FilesMatch>
### marker CORS end ###
### marker DROPQS start ###
CacheKeyModify -qs:fbclid
CacheKeyModify -qs:gclid
CacheKeyModify -qs:utm*
CacheKeyModify -qs:_ga
### marker DROPQS end ###
</IfModule>
## LITESPEED WP CACHE PLUGIN - Do not edit the contents of this block! ##
# END LSCACHE
# BEGIN NON_LSCACHE
## LITESPEED WP CACHE PLUGIN - Do not edit the contents of this block! ##
## LITESPEED WP CACHE PLUGIN - Do not edit the contents of this block! ##
# END NON_LSCACHE
# BEGIN WordPress
# The directives (lines) between "BEGIN WordPress" and "END WordPress" are
# dynamically generated, and should only be modified via WordPress filters.
# Any changes to the directives between these markers will be overwritten.
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
# Wordfence WAF
<IfModule LiteSpeed>
php_value auto_prepend_file '/home/ecobricks/public_html/wordfence-waf.php'
</IfModule>
<IfModule lsapi_module>
php_value auto_prepend_file '/home/ecobricks/public_html/wordfence-waf.php'
</IfModule>
<Files ".user.ini">
<IfModule mod_authz_core.c>
Require all denied
</IfModule>
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
</Files>
# END Wordfence WAF
php_value max_execution_time = 180
# New Ecobricks.org landing
<FilesMatch "\.(ico|pdf|flv|jpg|jpeg|png|webp|gif|js|swf|svg)$">
Header set Cache-Control "max-age=31536000, public"
</FilesMatch>
<FilesMatch "\.(css)$">
Header set Cache-Control "max-age=536000, public"
</FilesMatch>
#Alternate default index pages
DirectoryIndex welcome.php index.php
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST} ^ecoladrillo.org$ [OR]
RewriteCond %{HTTP_HOST} ^www.ecoladrillo.org$
RewriteRule (.*)$ https://ecoladrillo.org/es/$1 [R=301,L]
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/?(en|es|id|fr|pt|vi|wp-content|wp-includes|wp-admin|testing|pdfs)/
RewriteCond %{HTTP_HOST} ^www.ecobricks.org$ [OR]
RewriteCond %{HTTP_HOST} ^ecobricks.org$
RewriteCond %{HTTP:Accept-Language} ^id [NC]
RewriteRule (.*)$ https://ecobricks.org/id/$1 [R=301,L]
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/?(en|es|id|fr|pt|vi|briks|wp-content|wp-includes|wp-admin|pdfs|testing)/
RewriteCond %{HTTP_HOST} ^www.ecobricks.org$ [OR]
RewriteCond %{HTTP_HOST} ^ecobricks.org$
RewriteCond %{HTTP:Accept-Language} ^es [NC]
RewriteRule (.*)$ https://ecobricks.org/es/$1 [R=301,L]
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/?(en|es|id|fr|pt|vi|briks|wp-content|wp-includes|wp-admin|pdfs|testing)/
RewriteCond %{HTTP_HOST} ^www.ecobricks.org$ [OR]
RewriteCond %{HTTP_HOST} ^ecobricks.org$
RewriteCond %{HTTP:Accept-Language} ^fr [NC]
RewriteRule (.*)$ https://ecobricks.org/fr/$1 [R=301,L]
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/?(en|es|id|fr|pt|vi|briks|wp-content|wp-includes|wp-admin|pdfs|testing|)/
RewriteCond %{HTTP_HOST} ^www.ecobricks.org$ [OR]
RewriteCond %{HTTP_HOST} ^ecobricks.org$
RewriteCond %{HTTP:Accept-Language} ^en [NC]
RewriteRule (.*)$ https://ecobricks.org/en/$1 [R=301,L]
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/?(en|es|id|fr|pt|vi|briks|wp-content|wp-includes|wp-admin|pdfs|testing)/
RewriteCond %{HTTP_HOST} ^www.ecobricks.org$ [OR]
RewriteCond %{HTTP_HOST} ^ecobricks.org$
RewriteRule (.*)$ https://ecobricks.org/en/$1 [R=301,L]
</IfModule>
# ... copy block above for other languages ...
RedirectMatch "^/es/welcome.php" "/es/"
RedirectMatch "^/id/welcome.php" "/id/"
RedirectMatch "^/fr/welcome.php" "/fr/"
RedirectMatch "^/vi/welcome.php" "/vi/"
RedirectMatch "^/pt/welcome.php" "/pt/"
RedirectMatch "^/brikchain" "/en/brikchain.php"
Redirect /arc /en/arc.php
Redirect /arc/ /en/arc.php
Redirect /arc.php /en/arc.php
Redirect /principles /en/principles.php
Redirect /principles/ /en/principles.php
Redirect /principles.php /en/principles.php
Redirect /catalyst /en/catalyst.php
Redirect /catalyst/ /en/catalyst.php
Redirect /catalyst.php/ /en/catalyst.php
Redirect /2021-regenreport /en/regenreports.php
Redirect /2021-regenreport/ /en/regenreports.php
Redirect /2021-regen-report /en/regenreports.php
Redirect /2021-regen-report/ /en/regenreports.php
Redirect /en/2021-regen-report.php /en/regenreports.php
RedirectMatch "^/regenreports\/?$" "/en/regenreports.php"
RedirectMatch "^/regenreport\/?$" "/en/regenreports.php"
RedirectMatch "^/regenreport.php\/?$" "/en/regenreports.php"
Redirect /coefficients /en/coefficients.php
Redirect /coefficients/ /en/coefficients.php
Redirect /coeffecients /en/coefficients.php
Redirect /coeffecients /en/coefficients.php
RedirectMatch "^/richard\/?$" "/en/richard.php"
RedirectMatch "^/symposium\/?$" "/en/symposium.php"
RedirectMatch "^/faq\/?$" "/en/faqs.php"
RedirectMatch "^/faqs\/?$" "/en/faqs.php"
RedirectMatch "^/faqs.php\/?$" "/en/faqs.php"
RedirectMatch "^/sequest" "/en/sequest.php"
RedirectMatch "^/sequest/" "/en/sequest.php"
RedirectMatch "^/transition" "/en/transition.php"
RedirectMatch "^/transition/" "/en/transition.php"
RedirectMatch "^/about" "/en/about.php"
RedirectMatch "^/about/" "/en/about.php"
RedirectMatch "^about" "about.php"
RedirectMatch "^/what" "/en/what.php"
RedirectMatch "^/what/" "/en/what.php"
RedirectMatch "^/media" "/en/media.php"
RedirectMatch "^/media/" "/en/media.php"
RedirectMatch "^/media.php/" "/en/media.php"
RedirectMatch "^/build" "/en/build.php"
RedirectMatch "^/build/" "/en/build.php"
RedirectMatch "^/drop-off" "/en/drop-off.php"
RedirectMatch "^/drop-off/" "/en/drop-off.php"
RedirectMatch "^/drop" "/en/drop-off.php"
RedirectMatch "^/drop/" "/en/drop-off.php"
RedirectMatch "^/market/" "/en/drop-off.php"
RedirectMatch "^/market" "/en/drop-off.php"
RedirectMatch "^/marketplace/" "/en/drop-off.php"
RedirectMatch "^/marketplace" "/en/drop-off.php"
RedirectMatch "^/exchange" "/en/drop-off.php"
RedirectMatch "^/exchange/" "/en/drop-off.php"
RedirectMatch "^/exchange/dropoff-map/" "/en/drop-off.php"
RedirectMatch "^/brikcoins" "/en/brikcoins.php"
RedirectMatch "^/brikcoins/" "/en/brikcoins.php"
RedirectMatch "^/open-books" "/en/open-books.php"
RedirectMatch "^/openbooks" "/en/open-books.php"
RedirectMatch "^/openbooks/" "/en/open-books.php"
RedirectMatch "^/openbooks.php" "/en/open-books.php"
RedirectMatch "^/brickable/" "/en/brickable.php"
RedirectMatch "^/brikable/" "/en/brickable.php"
RedirectMatch "^/brickable/" "/en/brickable.php"
RedirectMatch "^/brickable" "/en/brickable.php"
RedirectMatch "^/brikable" "/en/brickable.php"
RedirectMatch "^/brickable" "/en/brickable.php"
RedirectMatch "^/earth-beta" "/earth.php"
RedirectMatch "^/earth/" "/earth.php"
RedirectMatch "^/modules-beta" "/en/modules.php"
RedirectMatch "^/modules-beta/" "/en/modules.php"
RedirectMatch "^/modules/" "/en/modules.php"
RedirectMatch "^/symposium" "/en/symposium.php"
RedirectMatch "^/symposium.php/" "/en/symposium.php"
RedirectMatch "^/simposium/" "/en/symposium.php"