Hello community!
I have a problem with nginx configuration.
I have installed a WP site with ee site create example.com --wpfc # install wordpress + nginx fastcgi_cache
The wordpress theme that is used does not adapt to mobile, so we use WPTouch plugin. I want to be able to bypass the cache when a user is mobile. But I cant manage it. I found this to detect mobile user agents: https://gist.github.com/perusio/1326701
So i have added that code into /etc/nginx/nginx.conf, and in my htdocs/nginx.conf file, I added:
location /{
if ($is_mobile) {
set $no_cache 1;
}
But that doesn't work. Can somebody help me? Thanks!