Add Woo and EDD defaults to page cache exclusions
This commit is contained in:
parent
95c7a53827
commit
c511e5272d
@ -23,12 +23,12 @@ if ($query_string != "") {
|
|||||||
set $skip_cache 1;
|
set $skip_cache 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
# Don't cache uris containing the following segments
|
# Don't cache URIs containing the following segments
|
||||||
if ($request_uri ~* "/wp-admin/|/wp-json/|/xmlrpc.php|wp-.*.php|/feed/|index.php|sitemap(_index)?.xml") {
|
if ($request_uri ~* "/wp-admin/|/wp-json/|/xmlrpc.php|wp-.*.php|/feed/|index.php|sitemap(_index)?.xml|/cart/|/checkout/|/my-account/") {
|
||||||
set $skip_cache 1;
|
set $skip_cache 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
# Don't use the cache for logged in users or recent commenters
|
# Don't use the cache for logged in users or recent commenters
|
||||||
if ($http_cookie ~* "comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_no_cache|wordpress_logged_in") {
|
if ($http_cookie ~* "comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_no_cache|wordpress_logged_in|edd_items_in_cart|woocommerce_items_in_cart") {
|
||||||
set $skip_cache 1;
|
set $skip_cache 1;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user