Support » Plugins and Hacks » [Plugin: WP Super Cache] Set it so it does not cache the index.php?

Viewing 10 replies - 1 through 10 (of 10 total)
  • You can’t. Sorry.

    Ouch 🙁

    Create a nocache-home.php in the wp-super-cache/plugins/ directory

    Put this in it…

    <?php
        if($_SERVER['REQUEST_URI'] == '/') $cache_enabled = false;
    ?>

    Should work.

    donncha can you please address this? There are a ton of posts about this problem on this board, and the problem of the newest versions of supercache substituting a category page for index.php at random.

    Also, would you say that you cannot use supercache if you use a static page as the home page? Also what do you think about Murmatron’s solution?

    I’d like to join the club:

    I’m unable to figure out how to exclude the home/index.php from cache. The front page shows ‘random posts’ from archive; therefore the cache should be turned off there.

    As the “index.php” ist not shown in the URL, I can not exclude it in the “Accepted Filenames & Rejected URIs”-Box.

    Any idea?

    Try this in the rejected URI textbox:

    ^/$

    Does that work for you? That should match a single /. If your path is different, add it in if necessary.

    Hi donncha,

    thank you for your quick response and support.
    Placing the exact string ^/$ in the rejected URL box seems to have no effect: the front page still goes into cache.
    When I replace ^ with the path of my blog it actually does block the cache … unfortunately of the entire blog pages.

    Is there any chance to place a string directly into the index.php to keep it from cache?

    Thank You again.

    Hi all,

    I’ve tried the solution, proposed by Murmatron 2

    Create a nocache-home.php in the wp-super-cache/plugins/ directory

    Put this in it…

    <?php
    if($_SERVER[‘REQUEST_URI’] == ‘/’) $cache_enabled = false;
    ?>

    Should work.

    This works perfectly for me (having a start page as a static page and using secondary loop).

    Thanks!

    UPD: If it might be of use, before testing I “refreshed” the page by editing to renew it’s caching. Now it doesn’t get in cache.

    Yes. It works – Great!

    How come I missed Murmatron2s solution? Well, it was late.
    Thank you shoo_ash for your ‘reminder’.

    It works… thanks guys 🙂

    Works here 🙂

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘[Plugin: WP Super Cache] Set it so it does not cache the index.php?’ is closed to new replies.