diff --git a/config.yml b/config.yml index f5cebc2..984afd9 100644 --- a/config.yml +++ b/config.yml @@ -11,7 +11,6 @@ jinja_environment: baseurl_abs: https://chaostreff.ch/ baseurl: / spaceapi_proxy_endpoint: /spaceapi-proxy - htaccess_language_redirect: no htaccess_spaceapi_proxy: yes hackerspaces: diff --git a/static-src/.htaccess b/static-src/.htaccess index 92c0737..38054c0 100644 --- a/static-src/.htaccess +++ b/static-src/.htaccess @@ -4,18 +4,12 @@ DirectoryIndex index.var index.html # Optional: Redirect to language specific subsite, rather than showing # language specific content at the root -{% if htaccess_language_redirect %} -{%- for language in languages %} -Redirect /index.{{ language }}.html /{{ language }}/ -{%- endfor %} -{%- endif %} - {% if htaccess_spaceapi_proxy %} # SpaceAPI proxy service workaround for missing CORS headers RewriteEngine on {%- for space in hackerspaces %} {%- if 'spaceapi' in space %} -RewriteRule ^/spaceapi-proxy{{ space.spaceapi }}$ {{ space.spaceapi.split('/', 2)[1] }}://{{ space.spaceapi.split('/', 2)[2] }} [P,L] +RewriteRule ^spaceapi-proxy{{ space.spaceapi }}$ {{ space.spaceapi.split('/', 2)[1] }}://{{ space.spaceapi.split('/', 2)[2] }} [P,L] {%- endif %} {%- endfor %} {%- endif %} diff --git a/static-src/index.var b/static-src/index.var index 2a3b26c..94afc3c 100644 --- a/static-src/index.var +++ b/static-src/index.var @@ -1,7 +1,7 @@ URI: index; vary="language" {% for language in languages %} -URI: index.{{ language }}.html +URI: {{ language }}/index.html Content-Type: text/html Content-Language: {{ language }} {% endfor %}