I have difficulties to apply this if statement in my nginx config:
location / {
break;
proxy_pass http://127.0.0.1:4444;
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
if ($arg_charset ~* windows-1251) {
charset windows-1251;
}
source_charset utf-8;
}
I have tried $arg_charset ~* "windows-1251" and $arg_charset ~* /.windows-1251./ and all others solutions. None does work... Removing if statements give me wanted results, so the problem is inside if statement condition.
It's a bug or i'm doing it wrong?