BuddyDev

Search

Replies

  • Keymaster
    (BuddyDev Team)
    Posts: 25058

    Hi,
    Welcome to BuddyDev support forums.

    Please put this code in your bp-custom.php

    
    
    function bpcustom_only_enable_for_group_admin_mod_posts( $stop_notification, $activity ) {
    
    	$group_id  = $activity->item_id;
    	$logged_id = get_current_user_id();
    	if ( ! groups_is_user_admin( $logged_id, $group_id ) && ! groups_is_user_mod( $logged_id, $group_id ) ) {
    		$stop_notification = true;
    	}
    	
    	return $stop_notification;
    }
    
    add_filter( 'bp_local_group_notifier_skip_notification', 'bpcustom_only_enable_for_group_admin_mod_posts', 10, 2 );
    
    

    That will limit it to group admin/mods.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25058
    Brajesh Singh on in reply to: Gallery Activity Posts #51421

    Hi Chris,
    Thank you for the question.

    The plugin does create 2 activity types(xyz created a gallery) and (xyz posted n images in gallery).
    Depending on the privacy of media/gallery, It might not be visible in the activity directory.

    Please make sure you have the activity types enabled in MediaPress->settings->BuddyPress section.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25058
    Brajesh Singh on in reply to: [Resolved] Group Notifier Plugin #51420

    Thank you. I am glad it is resolved!

  • Keymaster
    (BuddyDev Team)
    Posts: 25058
    Brajesh Singh on in reply to: [Resolved] Hiding users from widgets not working #51419

    Hi,
    Thank you for your patience.

    Please try using the following code

    
    
    /**
     * Exclude Users from BuddyPress Members List by WordPress role.
     *
     * @param array $args args.
     *
     * @return array
     */
    function buddydev2_exclude_users_by_role( $args ) {
    	// do not exclude in admin.
    	if ( is_admin() && ! defined( 'DOING_AJAX' ) ) {
    		return $args;
    	}
    
    	$excluded = isset( $args['exclude'] ) ? $args['exclude'] : array();
    
    	if ( ! is_array( $excluded ) ) {
    		$excluded = explode( ',', $excluded );
    	}
    
    	$role     = 'administrator';// change to the role to be excluded.
    	$user_ids = get_users( array( 'role' => $role, 'fields' => 'ID' ) );
    
    	$excluded = array_merge( $excluded, $user_ids );
    
    	$args['exclude'] = $excluded;
    
    	return $args;
    }
    
    add_filter( 'bp_after_core_get_users_parse_args', 'buddydev2_exclude_users_by_role' );
    

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25058
    Brajesh Singh on in reply to: [Resolved] Hiding users from widgets not working #51410

    Hi,
    Welcome to BuddyDev support.

    You are right about the issue.

    The problem is BuddyPress does not provide any hook to filter for user list.
    https://github.com/buddypress/buddypress/blob/master/src/bp-members/bp-members-blocks.php#L26

    There is a solution using bp_after_core_get_users_parse_args
    I haven’t posted it as it will run for all user queries irrespective of their context. That makes it inefficient for use.

    If you still want to proceed with it, Please let me know and I will share the code.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25058
    Brajesh Singh on in reply to: Activity Plus image clean up problem with re-poster. #51409

    Hi,
    Thank you for reporting the issue.

    Please allow us to look into it and assist you. I will be getting back to you over Monday with a possible solution.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25058
    Brajesh Singh on in reply to: Profile visibly not hiding profiles #51408

    Thank you.
    I am looking forward to your further feedback.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25058

    Hi,
    BuddyPress has removed the support for pages as directory in 12.0. If you install and activate BP Classic
    https://wordpress.org/plugins/bp-classic/

    You can use the pages as directory component.

    We are working on a non page solution. The problem is backward compatibility with older versions of BuddyPress. I am hoping to have a final resolution next week.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25058
    Brajesh Singh on in reply to: Buddypress & Mediapress integration #51406

    Hi Chris,
    I am sorry for your inconvenience.

    I can help you with swapping buttons but that is not sufficient enough to make it work with Youzer. It will need a lot more effort to make it work with Youzify plugin.

    I wish I could assist you with it. If possible, go with their media component for now as that is what the youzify team intends for its users.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 25058
    Brajesh Singh on in reply to: BuddyBoss Documents page PDF preview not working #51405

    Hi,
    Welcome to BuddyDev support forums!
    I am sorry, I will suggest contacting BuddyBoss support for it.
    https://support.buddyboss.com/support/tickets/new

    I aplogize for not being able to assist you here.

    Regards
    Brajesh