Hi!
WPO does not cache pages containing query parameters by default. This means that visiting a URL like …/events/exhibitions/abc-arts/?location=all&av=y will display the uncached version of the target page.
Therefore, there’s no need to set an exclusion rule.
You can confirm the cache status of any page containing query parameters in its URL by checking the page source code. You will see a WPO comment at the bottom stating whether the page is cached or not.
Regards.
Thread Starter
wrip
(@wrip)
Hi @deabiodun
Thanks for your reply. Let me just share some of the things I tried with some addition questions.
I tried exclusion rules like this:
/events/exhibitions/*
/events/expos/*
When I did this, I noticed something isn’t working on the pages like this:
https://mysite.com/events/exhibitions/abc-arts/?location=all&av=y
These parameters are dynamic AJAX calls that get triggered by radio buttons or dropdown selections on the /events/exhibitions/abc-arts/ page. I noticed that after adding the above exclusion rules, the AJAX calls didn’t display any results when the radio/dropdown were selected. I then removed the exclusion rules. Then the AJAX calls seemed to be working fine.
The WPO comment on the /events/exhibitions/abc-arts/ page always showed the following comment when I directly visited this page or if I selected the radio or dropdown selections:
Cached by WP-Optimize (gzip) - https://teamupdraft.com/wp-optimize/ - Last modified: 1 October 2025 9:21 am ....
When I select the radio or dropdown selections, the page url appends parameters without refreshing the entire page. Is this actually caching the AJAX calls?
However, if I directly visited the page with the parameters /events/exhibitions/abc-arts/?location=all&av=y, I saw the following comment:
WP Optimize page cache - https://teamupdraft.com/wp-optimize/ - Page not served from cache
Is this an expected behaviour?
Thread Starter
wrip
(@wrip)
Btw, my current settings are:
Enable page caching: On
"Automatically preload content after it is purged" checkbox: unticked
"Generate separate files for mobile devices" checkbox: unticked
"Serve cached pages to logged in users" checkbox: unticked
Cache lifespan: 24 hours
Gzip compression: Enabled
Browser static file caching headers: Enabled and expiration set to 5 days
Minify: Not enabled
What happens if you include /events/exhibitions/abc-arts/*
Is there any way we can have your site URL?
Thread Starter
wrip
(@wrip)
@vupdraft I think I had tried doing that as well but didn’t work.
Anyway, I changed Cache lifespan value from 24 hours to
Cache lifespan: 8 hours
and removed the URLs (that I had initially added) from the exclusion list. This now seemed to have resolved the issue for me. It’s almost a week now and the dynamic AJAX calls are working fine.
My AJAX implementation had custom nonce. I think the cache lifespan of 24 hours had some conflict with the custom nonce. After reducing it to 8 hours, all seemed to be working well. I still haven’t set the automatic preload enabled. I might give that a try as well. I hope that won’t cause any issues.