Shape the future of Social networking with WordPress: Join Project Midnight Sun! The next generation platform for community building with WordPress!

BuddyDev

Search

Replies

  • Keymaster
    (BuddyDev Team)
    Posts: 25398
    Brajesh Singh on in reply to: [Resolved] Stack error on settings page… #9238

    Hi,
    My apologies for the inconvenience.

    I just noticed, It should be throwing some error since we have missed to pass css class and forgot a check.

    I am putting a fix in MediaPress and pushing on github. It will be available with the next release. It won’t have any side effect. It is used to allow adding extra css class on the image selector.

    Thank you

  • Keymaster
    (BuddyDev Team)
    Posts: 25398

    Hi Henrik,
    Here is an example with font awesome. Please feel free to modify it and adapt with your own iconset.

    
    /**
     * Show Font awesome icon based on the member type
     */
    function buddydev_show_member_type_in_directory() {
    
    	$user_id = bp_get_member_user_id();
    	if ( ! $user_id ) {
    		return ;
    	}
    
    	$member_type = bp_get_member_type( $user_id, true );
    	$output = "";
    
    	if ( $member_type == 'kvinde' ) {
    		$output ='<i class="fa fa-venus" aria-hidden="true"></i>';
    	} elseif ( $member_type == 'mand' ) {
    		$output = '<i class="fa fa-mars" aria-hidden="true"></i>';
    	}
    
    	echo $output;
    }
    
    add_action( 'bp_directory_members_item', 'buddydev_show_member_type_in_directory' );
    
    

    Please put the code in bp-custom.php.
    Hope that helps.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25398

    Hi,
    Are you by any chance testing it as site administrator? The login redirect plugin will not redirect to your profile if you are a site administrator. It only does so for the non admin users.

    I am sorry for the confusion. Just tested with BuddyPress 2.8.2 & WordPress 4.7.5 and the plugin version 1.2.2.

    Can you please tell me if it is a different case for you.

  • Keymaster
    (BuddyDev Team)
    Posts: 25398

    Hi,
    Welcome to BuddyDev forums.

    Are you using any other redirection/restriction plugin too? If not, Please let me know. I will be able to check and update quickly.

    Thank you
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25398

    Well, It is a bad idea to use font awesome for just 2 icons.
    Also, just confirming that that the member type names are “male” and “female” or please let me know the correct member type names(unique names).

    Thank you
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25398

    Hi Henrik,
    Can you please confirm me if the Kleo theme uses font awesome ? If yes, I can post you the complete code to show the icon.

    Thank you
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25398
    Brajesh Singh on in reply to: [Resolved] Group list media #9220

    Hi Francoise.
    Can you please try running the same in the sidear and see if that works for the group.

    In the above code, we are explicitly asking to list all media types for current group.

  • Keymaster
    (BuddyDev Team)
    Posts: 25398

    Hi,
    Welcome to BuddyDev forums and thank you for posting it.

    Please allow us to investigate it today and post a solution by tomorrow.

    Thank you
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25398

    Hi Brett,
    I am sorry for not updating it.
    This plugin needs rewrite. We will be releasing an update in early June that fixes all bugs and adds support for the xprofile custom field types/our member type plugins.

    Thank you.

  • Keymaster
    (BuddyDev Team)
    Posts: 25398

    Hi Dandy,
    Thank you.
    I hope you are doing well too.

    Please put this code at the beginign of your js file

    
    
    jQuery('.item-list-tabs a').on('click', function(){
    
     jQuery(this).trigger("bp-ext-friendship-popover:close");
    });
    
    

    That should most probably work for all cases. Another solution is to use timeouts.