diff options
Diffstat (limited to 'nginx.inc.conf')
-rw-r--r-- | nginx.inc.conf | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/nginx.inc.conf b/nginx.inc.conf index b795a1c..acab0ef 100644 --- a/nginx.inc.conf +++ b/nginx.inc.conf @@ -14,19 +14,19 @@ location ~ ^/(css/font|js/lib)/ { location / { set $warned NO; if ($http_cookie ~ "warned") { - set $warned YES; + set $warned YES; } if ($args ~ "warned") { - set $warned YES; + set $warned YES; } if ($warned = NO) { - return 307 /warn.html; + return 307 /warn.html; } } -location /setcookie.html { +location /warned.ngx { add_header Set-Cookie "warned=1; Expires=Tue, 19 Jan 2038 00:00:00 GMT; HttpOnly"; - return 301 /; + return 301 "/warned.html?$args&language=$http_accept_language"; } location /warn.html { @@ -40,3 +40,5 @@ location /robots.txt { expires 5s; add_header Cache-Control public; add_header X-UA-Compatible "IE=edge"; + +# vim:ft=nginx: |