• Resolved sushilsth

    (@sushilsth)


    Hi Support Team,

    We have logic in the page where we make CURL request to third party URLs and based on the response, we filter the HTML section on the pages. This filtering HTML section logic work correctly when the cache is disabled. But, same thing won’t work when the cache is enabled.

    Below is the algorithm of filter the HTML section.
    1. Makes curl request to the third party URLs.
    2. We filter the HTML section to include/exclude based on the response we obtained from #1 CURL request.

    Any idea, why enabling the cache would hamper in such CURL request. Is there any settings that needs to be TURNED ON?

    Thank you.

Viewing 1 replies (of 1 total)
  • Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @sushilsth

    Thank you or your inquiry and I am happy to assist you with this.
    Well when the Page Cache is enabled, the HTML is cached. So the cache needs to be cleared for this to work as expected or disable the Page Cache.
    If on a specific page, you can add that page to “Never Cache following Pages” in Performance>Page Cache>Advanced:
    E.G.
    /your-page/

    Or you can disable caching for a specific template by adding define('DONOTCACHEPAGE', true); which will disable page caching for a given page.
    Thanks!

Viewing 1 replies (of 1 total)

The topic ‘HTML section not filtered after enabling the cache’ is closed to new replies.