• Resolved q-one

    (@q-one)


    Hi,

    I am currently having trouble to debug an issue that I have with wp super cache and dynamic cache content.

    When
    1. loading a page ABC the dynamic content gets rendered properly and shown
    2. refreshing the page reloads the created super cache file except instead of showing the dynamic content it shows the replacement tag

    This issue is really strange since I have exactly the same environment on my local machine where everything works as it should.

    I can’t get my head around why the hooks aren’t getting called or maybe why the replacement tag doesn’t get replaced by the dynamic content.

    I appended a little placeholder comment to the returning string in the “wpsc_cachedata” hook so I can see if the replacement is taken place. And it seems as the “wpsc_cachedata” hook only gets called once (the first time the cached page gets created and rendered). Afterwards when reloading the page the cached page doesn’t have the placeholder comment anymore.

    Did someone encountered the same or could give me hint why I get this strange behavior?

    Thanks a lot for the help!

    https://ww.wp.xz.cn/plugins/wp-super-cache/

Viewing 1 replies (of 1 total)
  • Thread Starter q-one

    (@q-one)

    Hi,

    me again. And I found the issue! It was because of the redirects made by the plugin in the .htaccess file.

    Unfortunately those redirects will cause the server to load directly the cached files instead of letting php do the dynamic content update?!

    I found it out by using the “Test Cache” button of the plugin where a message appears which says that I am using PHP cache and mod_rewrite is still declared in the .htaccess file. Once I deleted the entries created from wp cache the dynamic content replacement works with all the settings as it should.

    It would be good if the plugin would remove those entries when changing the cache mode. I understand that sometimes it is not wanted to remove those explicitly. But when changing modes the user could be asked if he wants to keep those changes.

    It would have save me a lot of headaches.

    Otherwise this plugin is a great tool to make your site really faster with a lot of settings to fine tune it to your needs!

Viewing 1 replies (of 1 total)

The topic ‘dynamic cache content not working correctly’ is closed to new replies.