BuddyDev

Search

BP Profile Visibility Manager Problem with messaging

  • Participant
    Level: Initiated
    Posts: 12
    Michael Cary on #35610

    I am using the BP Profile Visibility Manager On my website and have a problem. When user marks no for “list in member search”, then a “friend” starts to send a message, their name isn’t showing up for autocomplete in the recipient field. I am using Better messages plugin. Friends should be able to see each other in message autocomplete regardless of member directory settings. Please help!

  • Keymaster
    Level: Yogi
    (BuddyDev Team)
    Posts: 2459
    Ravi on #35640

    Hello Michael,

    Thank you for posting. Please try the following code and let me know if it works or not.

    
    
    add_filter( 'bp_profile_visibility_search_excluded_sql', function ( $exclude_sql ) {
    
    	if ( ! bp_is_members_directory() ) {
    		$exclude_sql = '';
    	}
    
    	return $exclude_sql;
    } );
    
    

    Regards
    Ravi

  • Participant
    Level: Initiated
    Posts: 12
    Michael Cary on #35648

    Hi Ravi, thanks for the message. Could you please tell me where to place that code?

  • Keymaster
    Level: Yogi
    (BuddyDev Team)
    Posts: 2459
    Ravi on #35649

    Hello Michael,

    You can place this code in ‘bp-custom.php’. For more info please look at the following resource:

    https://buddydev.com/docs/buddypress-guides/what-is-bp-custom-php/

    Regards
    Ravi

  • Participant
    Level: Initiated
    Posts: 12
    Michael Cary on #35682

    Ravi, thanks for trying to help, but I am not capable of adding the code you suggested to the proper place, when I do it, I get a critical error. Could you please make a update to the plugin so that this will work?

  • Keymaster
    Level: Yogi
    (BuddyDev Team)
    Posts: 2459
    Ravi on #35693

    Hello Michael,

    Please make a file with name “bp-custom.php” under plugins directory. Then put the following code:

    
    
    <?php
    /**
     * Modify profile visibility excluded sql
     *
     * @param string $exclude_sql Excluded sql.
     *
     * @return string
     */
    function buddydev_modify_profile_visibility_excluded_sql( $exclude_sql ) {
    
    	if ( function_exists( 'BP_Better_Messages' ) && ! bp_is_members_directory() ) {
    		$exclude_sql = '';
    	}
    
    	return $exclude_sql;
    }
    
    add_filter( 'bp_profile_visibility_search_excluded_sql', 'buddydev_modify_profile_visibility_excluded_sql' );
    
    

    Regards
    Ravi

  • Participant
    Level: Initiated
    Posts: 12
    Michael Cary on #35706

    Ravi, I’m sorry but that didn’t work. Another thing I noticed is that even though I am friends with the member who has no sleeted for visibility in directory and search, I do not see this member in my friends list. So this is two problems with the member visibility plugin-
    1. private member doesn’t show in message recipient autocomplete
    2. private member doesn’t show in my friends list.
    Thank you for all of your work I am confident you will find a way to fix this plugin to get these resolved.

  • Keymaster
    (BuddyDev Team)
    Posts: 21837
    Brajesh Singh on #35707

    Hi Michael,
    Thank you for the reply.

    1. We will update the plugin for the message sending issue.
    2. Please let me know your theme and which plugin are you using(BuddyPress or BuddyBoss platform)

    3. Please provide your order id too to allow us serve you in a timely manner.

    Thank you
    Brajesh

  • Participant
    Level: Initiated
    Posts: 12
    Michael Cary on #35710

    Hi Brajesh. so you will update the profile visibility manager plugin to allow message sending autocomplete as well as showing up in friends list?

    Here is the info you requested:

    Receipt number: 3749114940369886
    We’ll send confirmation to:
    eileen@webdesignjustforyou.com
    Merchant details
    Cosmic Coders Pvt. Ltd.
    Payment: #36394 BuddyPress Member Types Pro
    Payment: #36353 BuddyPress Profile Visibility Manager

  • Keymaster
    (BuddyDev Team)
    Posts: 21837
    Brajesh Singh on #35711

    Hi Michael,
    Thank you.

    Yes, we will update the plugin for the message sending. For friends, It works out of the box. Most probably, It is unable to find supporting hooks in the theme.

    Can you please tell me which theme are you using?

    Regards
    Brajesh

You must be logged in to reply to this topic.

This topic is: not resolved