Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Daniel Chatfield

    (@volcanicpixels)

    If you use the built in feature of the plugin to add a logout link then it will automatically only display when the user is logged in.

    Thread Starter kvdamme

    (@kvdamme)

    Thanks for your help, but I’m working on a client website and the menu needed to be hard coded.
    When the client creates a new page it automatically is added to the navigation in the right place without him having to add it manually.That’s why I can’t use the built in feature in this case.

    Isn’t there some conditional logic I can wrap around the link?

    Plugin Author Daniel Chatfield

    (@volcanicpixels)

    I believe this would work:

    $isLoggedIn = apply_filters( "private_blog_isLoggedIn" ), false );
    
    if($isLoggedIn){
    [display link code]
    }
    Thread Starter kvdamme

    (@kvdamme)

    I’m getting errors trying to use that function. It seems that the hook private_blog_isLoggedIn doesn’t exist.

    Can you give it another look please?

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Show logout link only when logged in’ is closed to new replies.