Support

Account

Forum Replies Created

  • Hi @elliot!

    It’s me once again. The simple solution would be the one displayed here

    So the following would work for me:

    echo ‘flush_all’ | nc localhost 11211

    or in PHP something like this:

    if ( file_exists( WP_CONTENT_DIR . ‘/object-cache.php’ ) &&
    $fp = fsockopen(“localhost”, 11211, $errno, $errstr, 30) ) {
    fwrite($fp, “flush_all\r\n”);
    $output = ”;
    while (!feof($fp))
    $output .= fgets($fp, 128);
    // do whatever you want with $output… what you should get is “OK”
    fclose($fp);
    }

    Cheers

    Günther

  • That would be even better – thanks @elliot!

  • Hi @elliot!

    It’s exactly what @Bienfeo and @unkulunkulu have already described. But let me try to be a bit more precise (and correct) on this issue:

    In case a file with the name “wp-content/object-cache.php” exists (which is provided by the quite common “Memcached” plugin “http://wordpress.org/extend/plugins/memcached/”, version 2.0.2), then updating of ACF values will fail (not creation though!).

    I was wondering if you could emit a simple pointer to this issue at the top of the ACF management section in the backend (“wp-admin/edit.php?post_type=acf”, which integrates the “create_options” method from each field type). That place would be where you get stuck in case you have an “wp-content/object-cache.php” installed and you could simply tell people:

    If you are unable to update ACF values, please try removing or renaming the file “wp-content/object-cache.php” from your installation.

    Cheers

    Günther

  • Just a quick note: had I found this post, it would have saved me 4 hours of research.


    @elliot
    – would you mind putting a simple warning message (with explanation) on top of “create_options” in case a “cache-object.php” file exists? (just simply verify what we experienced by installing it and trying to change the default value of an ACF after having “memcached” installed)

    Thanks!

    Günther

Viewing 4 posts - 1 through 4 (of 4 total)