Skip to:
Content
Pages
Categories
Search
Top
Bottom

Forum Replies Created

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

  • AliceG
    Participant

    @aliceg

    It’s working !! Your f***ing so strong 🙂 You saved my week !
    Thank you a lot


    AliceG
    Participant

    @aliceg

    Thank you for your reply.
    Actually, I have a button “My group” and a none display bloc where I put this code, and a jquery shows all my groups on clic :

    <?php 
    $group_ids = groups_get_user_groups(bp_displayed_user_id());
    foreach($group_ids["groups"] as $group_id) { 
    echo('<a title="Aller sur le groupe" href="' . home_url() . '/groupes/' . groups_get_group(array( 'group_id' => $group_id )) -> slug . '">' .groups_get_group(array( 'group_id' => $group_id )) -> name . '</a>' . (end($group_ids["groups"]) == $group_id ? '' : ', ' ) ); } 
    ?>

    So this code is working on my profile page, I have all my groups. On a group page, only the group where I am shows, and everywhere else there is no list.

    So do you have an idea to show a list of “my group” everywhere?
    Thank you a lot !


    AliceG
    Participant

    @aliceg

    Thank you for your reply. I will put all my “solutions” here :

    Last solutions :

    $is_friend = friends_check_friendship( bp_loggedin_user_id(), bp_displayed_user_id() );
    
    if($is_friend) {
       bp_member_profile_data();
    }

    This work but only show the count, and I would like the avatars and links :

    if ( is_user_logged_in() ) :
    		if ( bp_is_active( 'friends' ) ) :	
    
    			echo '<br/><br/>'. bp_get_total_friend_count( $user_id ) .'';
    			  
    		endif;
    	endif;

    This shounl be a good idea… but it shows all my members…

    if ( bp_has_members( 'user_id optional=true') ) : ?>
    <?php bp_get_template_part( 'members/members-loop' ) ?>
    <?php endif; 

    Do you know the action code to display realy easily?
    Thank you !

Viewing 3 replies - 1 through 3 (of 3 total)
Skip to toolbar