• Resolved lukework

    (@lukework)


    Hi,
    Love this plugin. I ran into an issue though, I turned off “Bypass the cache for logged-in users” and I still see the swcfpc=1 query on every URL when I’m logged in. This causes issues with caching as CloudFlare will cache my logged in visits on a fresh cache with the query added to all URLs, bypassing the cache altogether.

    Is there a way to turn this query off?

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Contributor Salvatore Fresta

    (@salvatorefresta)

    Hi @lukework ,
    why do you want to disable cache bypass for logged in users? If you do, you risk making public pages and information that must remain private.

    The cache buster is essential for this plugin to work properly with the cloudflare free plan. If you don’t like the name, you can change it using the PHP constant SWCFPC_CACHE_BUSTER in your wp-config.php.

    Example:

    define('SWCFPC_CACHE_BUSTER', 'cache-buster');

    If you continue to see the cache buster even after disabling the plugin, it means that you still have the pages cached. Clear your cache first.

    Thread Starter lukework

    (@lukework)

    I was using the page rule this plugin uses for several years before I found this plugin. I started using it because the official CloudFlare plugin is not clearing the cache properly on content updates.

    The problem I’m having now is that I’m seeing “swcfpc=1” on every URL after I’ve cleared the CloudFlare cache and logged out (or used incognito mode in my browser). Every link on my site ends up having “swcfpc=1” added to it, so my concern is that every URL on my site is bypassing the CF cache. That’s why I want to turn that functionality off.

    I have page rules set up not to cache anything in /wp-admin/, the site toolbar is off globally, and my previous setup without this plugin was working great until the official CloudFlare plugin stopped working, so there really isn’t an issue on my setup exposing private pages.

    Plugin Contributor Salvatore Fresta

    (@salvatorefresta)

    Hi @lukework ,
    the cache buster is added for internal links only and only while you are logged in. If you see it also while you are logged out, there is something wrong in your environment.

    Please make sure there is only one page rule on your cloudflare settings, the only one created by this plugin. You don’t need additional page rules.

    Make sure that cloudflare is respecting original http headers.

    You must bypass the cache for logged in users.

    Purge the whole cache and test again

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘swcfpc=1 still on every page despite disabling’ is closed to new replies.