Wordpress LScache Plugin: exclude products from purge
Last Updated on: Wed, 15 Apr 2026 00:00:02 Hi! is there a way to ?exclude products by WooCommerce from Purge? I have 700 products and i Dont want any site to be purged, otherwise its really slow. Thanks so much! I tried adding this, but somehow it still purges the products somehow: add_action(woocommerce_update_product, lscwp_suppress_purge_product_update, 10, 2) function lscwp_suppress_purge_product_update($product_id, $product) ob_start( function($buffer) use ($product_id) @header( X-LiteSpeed-Purge: . LSWCP_TAG_PREFIX . _Po. . $product_id . , . LSWCP_TAG_PREFIX . _WC_S ) return $buffer ) The page I need help with: https://esx-scripts.com X-LiteSpeed-Purge: public,6b8_UCSS.9cde3231c67ee69986ec73ba47eab5fe => LiteSpeed LSC->send_headers()@560 => WP_Hook->apply_filters(ARRAY)@307 => WP_Hook->do_action(ARRAY)@331 => /var/www/vhosts/esx-scripts.com/public_html/wp-includes/load.php@476 What do you think will happen if cache for product pages are excluded from being cached, but categories or search result pages cache is purged and you make any changes at the product details? @header( X-LiteSpeed-Purge: . LSWCP_TAG_PREFIX . _Po. . $product_id . , . LSWCP_TAG_PREFIX . _WC_S ) this line here is exactly what tells the server to purge the product page cache change it to @header( X-LiteSpeed-Purge: nothing ) this will suppress purge for ANY page when you update a product
LiteCache Rush: Speed comes from using less, not from doing it faster
Reference