Hello,
Thank you before for great tutorial.
I have running nginx with wordpress base on your tutorial at https://rtcamp.com/wordpress-nginx/tutorials/single-site/fastcgi-cache-with-purging/. It works well.
When I try to install woocommerce and follow the tutorial at https://rtcamp.com/wordpress-nginx/tutorials/plugins/woocommerce/, I have trouble to make nginx running when adding:
location ~ .php$ {
set $rt_session “”;
if ($http_cookie ~* "wc_session_cookie_[^=]*=([^%]+)%7C") {
set $rt_session wc_session_cookie_$1;
}
if ($skip_cache = 0 ) {
more_clear_headers "Set-Cookie*";
set $rt_session "";
}
fastcgi_cache_key "$scheme$request_method$host$request_uri$rt_session";
try_files $uri =404;
My fastcgi cache like this:
location ~ .php$ {
try_files $uri /index.php;
include fastcgi_params;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_cache_bypass $skip_cache;
fastcgi_no_cache $skip_cache;
fastcgi_cache WORDPRESS;
fastcgi_cache_valid 60m;
}
Can you help me?
Regards,
Dave