New
PeoplePress is here. Community building for WordPress, reimagined. Fast, modern, and built for the communities you've always wanted to run.
See it live

BuddyDev

Search

Replies

  • Keymaster
    (BuddyDev Team)
    Posts: 25513
    Brajesh Singh on in reply to: [Resolved] BuddyPress xprofile fields #21396

    Hi Vivek,
    No,
    The answer was in context to “member type field”.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25513

    Hi Joss,
    I am using the hook provided by you in the previous reply

    
    gwangi_buddypress_member_xprofile_custom_fields
    

    Please ask the theme developer for the correct hook or you can use the updated code like this

    
    
    function buddydev_show_pmpro_membership_level_in_dir() {
    	if ( ! bp_is_members_directory() ) {
    		return;
    	}
    	// for the logged in user.
    	$level = pmpro_getMembershipLevelForUser( bp_get_member_user_id() );
    
    	if ( ! $level ) {
    		return;
    	}
    
    	echo '<div class="bp-member-xprofile-custom-field bp-member-level">' . $level->name . '</div>';
    }
    
    add_action( 'gwangi_buddypress_member_xprofile_custom_fields', 'buddydev_show_pmpro_membership_level_in_dir', 10 );
    

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25513
    This reply has been marked as private.
  • Keymaster
    (BuddyDev Team)
    Posts: 25513

    Hi Adi,
    You are welcome. Glad that I was able to assist.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25513

    No problem.
    You are welcome 🙂

  • Keymaster
    (BuddyDev Team)
    Posts: 25513
    Brajesh Singh on in reply to: BuddyPress Activity Shortcode #21385

    Hi Max,
    Thank you for asking.

    I am not sure what kind of lazy load you are referring to. Is it about images? It will depend on the plugin/code offering lazyload whether they will work with it or not(they work with selectors most of the time). My suggestion will be to give a try and see how it goes.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25513
    Brajesh Singh on in reply to: BuddyPress Member Types Pro question #21384

    Hi Irene,
    Thank you for the details.

    Please allow me to look at it and get back to you later today.

    Thank you
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25513

    Hi Jack,
    I am sorry, It is not possible to show the javascript for it. I will suggest updating the theme to make the notice a bit more prominent. That should help in long run.

    All the best.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25513
    Brajesh Singh on in reply to: [Resolved] BuddyPress xprofile fields #21382

    Hi Vivek,
    Please add this to your bp-custom.php.

    I have allowed all image types.

    
    
    /**
     * Add images types to allowed file extension.
     *
     * @param array $extensions all extension.
     *
     * @return mixed
     */
    function buddydev_custom_profile_field_type_file_extensions( $extensions ) {
    
    	$extensions['file'] = array_merge(
    		$extensions['file'],
    		array(
    			'jpg',
    			'jpeg',
    			'gif',
    			'png',
    		)
    	);
    
    	return $extensions;
    }
    
    add_filter( 'bpxcftr_allowed_extensions', 'buddydev_custom_profile_field_type_file_extensions' );
    
    

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25513
    This reply has been marked as private.