Skip to:
Content
Pages
Categories
Search
Top
Bottom

Block This Page From Logged Out Users?

  • Avatar of tduschei
    tduschei
    Participant

    @tduschei

    I am trying to block from logged out users http://www.ukraxdemo.com/what15102/lifestories/ which I have added to the Buddypress loop. What I have been trying is not working, and I have been stuck on this for sometime. Tips please :)

    <?php

    if(is_page( $bp->displayed_user->id . ‘/lifestories/’ ) ) {

    if ( is_user_logged_in() ) {

    echo “We will show lifestories page to loggedin users”;
    }
    else
    {
    echo “We will not show lifestories page to loggedout users”;
    }

    }
    else
    {
    echo “We will not have anything here. All other pages will be unaffected”
    }

    ?>

Viewing 3 replies - 1 through 3 (of 3 total)
  • Avatar of meg@info
    meg@info
    Participant

    @megainfo

    hi @tduschei, i suggest you use private-community-for-bp-lite plugin by @bp-help

    http://wordpress.org/plugins/private-community-for-bp-lite

    Avatar of tduschei
    tduschei
    Participant

    @tduschei

    Thanks very much for the response meg@info.

    Unfortunately, that plugin creates difficulty with one of my other plugins, which I must have. In addition, I might want to create an additional parameter in the future, ex: If user account number = this.

    Therefore any other suggestions? :) I wish there was something I could do from functions.php.

    Thanks,
    -Tom

    Avatar of tduschei
    tduschei
    Participant

    @tduschei

    Sorry I mean @meg@info.

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

You must be logged in to reply to this topic.