Revision 7974
Added by Aaron Marcuse-Kubitza over 11 years ago
.htaccess | ||
---|---|---|
12 | 12 |
RewriteCond %{HTTP_HOST} ^www\.(.*)$ |
13 | 13 |
RewriteRule ^.*$ http://%1/$0 [redirect] |
14 | 14 |
|
15 |
# don't rewrite existing paths |
|
16 |
RewriteCond %{REQUEST_FILENAME} -d [ornext] |
|
17 |
RewriteCond %{REQUEST_FILENAME} -f [ornext] |
|
18 |
RewriteCond %{REQUEST_FILENAME} -l |
|
19 |
RewriteRule ^.*$ - [last] |
|
20 |
|
|
15 | 21 |
# translate subdomain to prefix |
16 | 22 |
RewriteCond %{HTTP_HOST} ^([^.]*)\.(.*)$ |
17 | 23 |
RewriteCond %{DOCUMENT_ROOT}/%1 -d [ornext] |
... | ... | |
20 | 26 |
RewriteCond %{DOCUMENT_ROOT}/%1/.htaccess -f |
21 | 27 |
RewriteRule ^.*$ %1/$0 [nosubreq] # avoid infinite recursion |
22 | 28 |
|
23 |
# don't rewrite existing paths |
|
24 |
RewriteCond %{REQUEST_FILENAME} -d [ornext] |
|
25 |
RewriteCond %{REQUEST_FILENAME} -f [ornext] |
|
26 |
RewriteCond %{REQUEST_FILENAME} -l |
|
27 |
RewriteRule ^.*$ - [last] |
|
28 |
|
|
29 | 29 |
# translate path head to dir |
30 | 30 |
RewriteCond %{DOCUMENT_ROOT}/$1 -d [ornext] |
31 | 31 |
RewriteCond %{DOCUMENT_ROOT}/$1 -l |
Also available in: Unified diff
web/vegpath/.htaccess: don't rewrite existing paths: Moved before other RewriteRules so that page dependencies (such as util.js) can be loaded more quickly without needing to pass through all the rewrite rules first