Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support andrewshu

    (@andrewshu)

    Hello @hokopt

    Sorry, I can’t understand your question. Please describe it in more detail.

    Regards.

    Thread Starter hokopt

    (@hokopt)

    Hi,
    On the post listing page I marked all private post titles (with UM-WP) with a padlock, via functions.php.

    function add_lock_access ( $new_title ) {
    if( !is_user_logged_in() && in_category('newsumwp') /* && !um_user( $data ) */ ) {
    $new_title = '<i class="iconlock" style="color:red;"></i> ' . $new_title;
    }
    return $new_title;
    }
    add_filter( 'the_title', 'add_lock_access' );


    Anyone who is not logged in sees the padlock, a user who logs in to see restricted content (UM-WP) the padlock is not displayed.

    I am currently running W3TC with cache in which a user without a login, if they click on a title with a padlock, is redirected to the login, that is, even with pagecache does not display the UM-WP content without login.

    How can I configure the W3TC to have pagecache for logged in users and ensure that those who are logged in do not see the padlock added to the post titles?

    Regards.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Exclude CACHE – Restrict access to this post’ is closed to new replies.