BuddyDev

Search

[Resolved] Link Page to BuddyPress Groups – error with wordpress-social-login plugin

  • Participant
    Level: Initiated
    Posts: 1
    i.Kay on #4668

    hi.. I don’t know if you support free member like me or not.

    I tried to install your “Link Page to BuddyPress Groups” to a multisite.

    When I added the “

    add_filter( 'bp_allow_fronted_group_page_liking', '__return_true' );

    ” into the bp-custom.php, following notice is what I have got.

    “add_filter( ‘bp_allow_fronted_group_page_liking’, ‘__return_true’ );
    Warning: session_start(): Cannot send session cache limiter – headers already sent (output started at /home/…/wp-content/plugins/bp-custom.php:5) in /home/…/wp-content/plugins/wordpress-social-login/wp-social-login.php on line 64”..

    and the code around line 64 of the wp-social-login.php is:

    // --------------------------------------------------------------------
    
    session_id() or session_start();
    
    global $WORDPRESS_SOCIAL_LOGIN_VERSION;
    global $WORDPRESS_SOCIAL_LOGIN_PROVIDERS_CONFIG;
    global $WORDPRESS_SOCIAL_LOGIN_COMPONENTS;
    global $WORDPRESS_SOCIAL_LOGIN_ADMIN_TABS;
    
    $WORDPRESS_SOCIAL_LOGIN_VERSION = "2.3.0";
    
    $_SESSION["wsl::plugin"] = "WordPress Social Login " . $WORDPRESS_SOCIAL_LOGIN_VERSION;
    
    // --------------------------------------------------------------------

    I look forward to hearing from you.
    Best regards,

  • Participant
    Level: Initiated
    Posts: 1
    i.Kay on #4669

    this is the line 64:

    session_id() or session_start();

    thanks

  • Keymaster
    (BuddyDev Team)
    Posts: 22202
    Brajesh Singh on #4671

    Hi,
    It is causing the error since you haven’t used the php tag. The code example assumed users will have it already. Please change the bp-custom.php file to this

    
    
    <?php
    add_filter( 'bp_allow_fronted_group_page_liking', '__return_true' );
    
    

    and it will work. Make sure that there are no space/newline before the starting

You must be logged in to reply to this topic.

This topic is: resolved