Title: bypass_cache filter
Last modified: March 12, 2020

---

# bypass_cache filter

 *  [davemktg86](https://wordpress.org/support/users/davemktg86/)
 * (@davemktg86)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/bypass_cache-filter/)
 * Hi,
    I continue having cache issue with my cookie banner. I try to exclude stm_gdpr_cookie
   as suggest my GDPR plugin author, but if I exclude this cookie I exclude all 
   my site page from caching. (if I understand right) I try to exclude entire plugin,
   but it seems this isn’t possible. So I’m trying to use bypass_cache filter but,
   it seems it doesn’t work properly.
 * I added this row to my function.php file:
    `add_filter( 'bypass_cache', 'displayPopup')`
   where displayPopup is the GDPR plugin function that manage cookie popup.
 * result:
    1# with “Pre-compression of cached pages” (in cache enabler settings)
   activated, popup never appears and my site doesn’t release cookies. 2# with “
   Pre-compression of cached pages” deactivated nothing changes. The popup appear
   at the first access(site serves a not cached page). If I accept cookie consent,
   popup desappears but it reappers when I return on first access page(site serves
   a cached page with popup).
 * Is there something I’m doing wrong?
 * Please note that this is a cache enabler issue beacause if I deactivate plugin
   all work properly and GDPR plugin author said me that all customers are using
   this plugin without issue simly excluding cookie plugin from cache plugin….
 * thank you very much
    regards
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fbypass_cache-filter%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

The topic ‘bypass_cache filter’ is closed to new replies.

 * ![](https://ps.w.org/cache-enabler/assets/icon.svg?rev=2442383)
 * [Cache Enabler](https://wordpress.org/plugins/cache-enabler/)
 * [Support Threads](https://wordpress.org/support/plugin/cache-enabler/)
 * [Active Topics](https://wordpress.org/support/plugin/cache-enabler/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/cache-enabler/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/cache-enabler/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [davemktg86](https://wordpress.org/support/users/davemktg86/)
 * Last activity: [6 years, 2 months ago](https://wordpress.org/support/topic/bypass_cache-filter/)
 * Status: not resolved