Skip to:
Content
Pages
Categories
Search
Top
Bottom

Start Page for not logged in visitors

  • Avatar of roman
    roman
    Participant

    @romanriebow

    hi,

    i do have the main activity stream as startpage which is great, but i would like to have a different start page for visitors (users which are not logged in or do not have an account yet).
    Something to explain what this site does and how it works and so on- is that possible? any idea for an existing plugin?

    thanks and best regards
    romanski

Viewing 1 replies (of 1 total)
  • Avatar of shanebp
    shanebp
    Moderator

    @shanebp

    Try this…
    Create bp-custom.php, it will go in /wp-content/plugins
    Add this code to it, change “/login-or-join” to whatever your page name is :
    `
    function login_intercepts(){
    /* if not logged in, user is sent to another page */
    if ( !is_user_logged_in() ) {
    bp_core_redirect( get_option(‘siteurl’).”/login-or-join” );
    }
    }
    add_action( ‘wp’, ‘login_intercepts’, 3 );
    `

Viewing 1 replies (of 1 total)

You must be logged in to reply to this topic.