Group Mods

  • Profile picture of r-a-y
  • Profile picture of Hugo
  • Profile picture of @mercime

Support: Miscellaneous

Everything else.

Splash Start (8 posts)

Started 2 years ago by: elaineskapetis

  • Profile picture of elaineskapetis elaineskapetis said 2 years ago:

    I’m trying to make a no-user-logged start site with Toutorials videos and somethings like this.
    I wrote

    ( is_user_logged_in() ) 

    I get my normal content

     else 

    I get the splash with Videos,Connect or Sign up

    But the problem is that I have to write

      if ( is_user_logged_in() ) 

    and when is register page I get the normal content.I was trying something like this

     if ( is_user_logged_in() )  || is_page('register')  

    ,but unfortunately nothing.

    somebody knows what I make wrong?

    Thanks

  • Profile picture of r-a-y r-a-y said 2 years ago:

    What would be better is if you created a page with video and tutorials, then you could use something like this:

    http://buddypress.org/community/groups/how-to-and-troubleshooting/forum/topic/how-to-make-a-private-community/?topic_page=3&num=15#post-44729

    Just change bp_core_redirect() to the page you want to redirect your users to if they’re not logged in.

  • Profile picture of elaineskapetis elaineskapetis said 2 years ago:

    Thank’s ray
    I gonna try. ;)

  • Profile picture of elaineskapetis elaineskapetis said 2 years ago:

    Let’s see if I understood.
    I have to use

    if (!is_user_logged_in() ){
    bp_core_redirect( $bp->root_domain.’/register’ );
    }

    than I can redirect my user to register page and ther could I put some Videos?
    Do I have to make this to all pages that I don’t wanna show to not logged in users?

  • Profile picture of elaineskapetis elaineskapetis said 2 years ago:

    It works now ;)
    I use the code from @Travel-Junkie
    by Functions:
    function sh_walled_garden()
    {
    global $bp;

    if ( bp_is_register_page() || bp_is_activation_page() )
    return;

    if( ! is_user_logged_in() )
    bp_core_redirect( $bp->root_domain .’/’. BP_REGISTER_SLUG );
    }
    add_action( ‘get_header’, ‘sh_walled_garden’ );

    and by header:
    do_action( ‘sh_walled_garden’ )

    Now I gonna make some changes by Register.

    Thanks a lot @ray and @Travel-Junkie ;)

  • Profile picture of r-a-y r-a-y said 2 years ago:

    @ElaineSkapetis – you actually don’t need the “do_action( ’sh_walled_garden’ )” line in header.php!

    Glad you figured it out.

  • Profile picture of hibuddie9ja hibuddie9ja said 6 months, 3 weeks ago:

    pls can somone help with a tutorial or a guide line on how i can make a splash front page look of my site like the following sites listed below which is facebook.com splash page, netlog.com or tagged splash…

  • Profile picture of aces aces said 6 months, 3 weeks ago:

    Things have changed since 18 months ago so it would be better to start a new topic.

    If you are interested in the walled garden privacy technique then for a much more recent discussion have a look here