Created
March 8, 2017 18:45
-
-
Save auniverseaway/b38170a60f71f5c5363c128a3b0e748a to your computer and use it in GitHub Desktop.
Vhost Redirect Block
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SetEnvIfNoCase Request_URI "^/([^/]+)/([^/]+)" LOCALE=$1/$2 | |
<If "tolower(%{ENV:LOCALE}) in {'hr/hr', 'il/he', 'mena/ar', 'ro/ro', 'sk/sk', 'si/si', 'ua/ua', 'si/en', 'ee/en', 'kr/ko', 'in/en', 'sea/en', 'tw/zh-Hant', 'hk/zh-Hant', 'hk/en', 'bg/en', 'lv/en', 'mx/es', 'gr/en', 'nl/nl', 'be/nl', 'lu/en', 'ca/en', 'sk/en', 'il/en', 'ch/fr', 'be/fr', 'lu/fr', 'mena/en', 'mt/en', 'se/sv', 'be/en', 'lt/en', 'ro/en', 'it/it', 'no/no', 'lu/de', 'za/en', 'at/de', 'de/de', 'es/es', 'cy/en', 'ru/ru', 'nz/en', 'ie/en', 'uk/en', 'dk/da', 'ca/fr', 'fi/fi', 'la/es', 'mena/fr', 'ua/en', 'rs/en', 'hr/en', 'br/pt', 'pt/pt', 'ch/de', 'pl/pl', 'jp/ja', 'fr/fr', 'ch/it', 'tr/tr', 'hu/hu', 'langmaster/en', 'au/en', 'us/en', 'cn/zh-Hans', 'cz/cs'}"> | |
ErrorDocument 404 /%{ENV:LOCALE}/404.html | |
ErrorDocument 500 /%{ENV:LOCALE}/500.html | |
</If> | |
<Else> | |
ErrorDocument 404 /us/en/404.html | |
ErrorDocument 500 /us/en/500.html | |
</Else> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment