Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'private'

Viewing 25 results - 251 through 275 (of 3,498 total)
  • Author
    Search Results
  • #311874
    welsh10
    Participant

    Hi,

    Does anyone know how to remove the Join Group option for Private groups based on a WP Role?
    Was thinking of using below, but need to work out how the button is called.

    $current_user = new WP_User(wp_get_current_user()->id);
    $user_roles = $current_user->roles; 
    foreach ($user_roles as $role) {
    
       if  ($role == 'subscriber' ){
         //code here for subscribers
       }
    
    Thanks to anyone who helps
    
    kitakitune
    Participant

    Hello! Thanks for the great plugins.
    I’m writing this question using a translation software because I’m Japanese and I don’t speak English.
    I’m sorry if it’s hard to read.

    What I want you to help me with is exactly what the title says.
    The private messaging feature, which works in legacy, doesn’t work in Nouveau.

    I first tried the contents of the two URLs below.
    It was 19 months ago, but only because it was so similar to the current situation.
    I’ve removed “https://” from the URL.

    buddypress.org/support/topic/private-message-button-not-working-right/

    buddypress.trac.wordpress.org/ticket/7908

    But since it didn’t improve, the

    I installed the version of “6.0.0-RC2” on this site to make sure that it was fixed.
    However, the situation did not change.

    I was wondering if it was something I was going through.
    I tried everything I could to stop all other plugins, verify with various themes, change the PHP version, clear the cache, reinstall, etc., but it didn’t improve.

    The Nouveau feature is great, and I’d like to be able to use it somehow.

    Please help me.

    Below.
    buddypress.org/support/topic/when-asking-for-support-2/
    I also wrote a response to the list I found in
    I’m sorry if I’m wrong in my perception.

    1. which version of WordPress are you running?

    Answer: “Version 5.4.1-en.

    2. did you install WordPress as a directory or subdomain installation?
    I did a quick install against the domain on the server.
    If the directory is installed, is it in the root or subdirectory?

    4. Have you upgraded from a previous version of WordPress? If so, from which version?
    One front.

    5. was WordPress working properly before installing/upgrading BuddyPress (BP)? Examples: permalinks, creating a new post, comments.
    It was functioning properly.

    6. What version of BP are you running?
    6.0.0-RC2.

    7.Have you upgraded from a previous version of BP? If so, from which version?
    5.2.

    Are there any plugins other than BuddyPress installed and activated? If so, which one is it?
    BuddyPress is not surprising.

    9.Are you using a standard WordPress theme or a customized theme?
    It’s standard stuff.

    10.Which theme do you use?
    TWENTY SEVENTEEN.

    11. Have you changed the core file in any way?
    No.

    Is there a custom function in bp-custom.php?
    No.

    13. if you’re running bbPress, which version is it? Or do you have bbPress built into your BuddyPress installation?
    No, I’m not using it.
    14.Please provide a list of errors in the server log file: codex.wordpress.org/Debugging_in_WordPress
    Is this it?
    Notice: Trying to access array offset on value of type int in /home/xx/tarianpapa.com/public_html/wp-includes/formatting.php on line 904

    15. Which company offers your hosting?
    //www.xserver.ne.jp/でしょうか
    16.Is the server running Windows, or if it’s Linux…Apache, nginx or something else?
    It’s a server called the X server, I think it’s Windows.
    17. Which BP theme do you use?
    If you mean NOUVEAU or Legacy, then NOUVEAU.
    18. did you overload the BuddyPress template file?
    I don’t think they did.
    19. Are there any other site customizations that you think are relevant to the problem?
    No, sir.

    Basic troubleshooting.

    BP Themes: Is this issue specific to the theme set in Dashboard->Settings->BuddyPRess->Options?
    It only happens in NOUVEAU.
    You can use the private message feature normally in Legacy.

    woofy123
    Participant

    @shanebp

    Hi, thanks for your reply before. I checked with the creators of the plugin and they say they can’t do it. so i decided to check by myself….the wise chat plugin redirects notifications to the email and the code for that is below….i don’t know coding and all that so i seriously need your help…what code do i put inplace of the email so that messages are reduirected to buddypress notifications? Please help..The code—–

    `<?php

    /**
    * WiseChat user notifications services.
    *
    * @author Kainex <contact@kaine.pl>
    */
    class WiseChatUserNotificationsService {

    /**
    * @var WiseChatUserNotificationsDAO
    */
    private $userNotificationsDAO;

    /**
    * @var WiseChatSentNotificationsDAO
    */
    private $sentNotificationsDAO;

    /**
    * @var WiseChatUsersDAO
    */
    private $usersDAO;

    /**
    * @var WiseChatChannelUsersDAO
    */
    private $channelUsersDAO;

    /**
    * @var WiseChatHttpRequestService
    */
    private $httpRequestService;

    /**
    * @var WiseChatOptions
    */
    private $options;

    public function __construct() {
    $this->options = WiseChatOptions::getInstance();
    $this->userNotificationsDAO = WiseChatContainer::getLazy(‘dao/WiseChatUserNotificationsDAO’);
    $this->sentNotificationsDAO = WiseChatContainer::getLazy(‘dao/WiseChatSentNotificationsDAO’);
    $this->usersDAO = WiseChatContainer::get(‘dao/user/WiseChatUsersDAO’);
    $this->channelUsersDAO = WiseChatContainer::get(‘dao/WiseChatChannelUsersDAO’);
    $this->httpRequestService = WiseChatContainer::getLazy(‘services/WiseChatHttpRequestService’);
    }

    /**
    * Sends all notifications for message.
    *
    * @param WiseChatMessage $message
    * @param WiseChatChannel $channel
    */
    public function send($message, $channel) {
    foreach ($this->userNotificationsDAO->getAll() as $notification) {
    $this->sendNotification($message, $channel, $notification);
    }
    }

    /**
    * Sends the notification.
    *
    * @param WiseChatMessage $message
    * @param WiseChatChannel $channel
    * @param WiseChatUserNotification $notification
    */
    private function sendNotification($message, $channel, $notification) {
    if ($notification->getType() == ’email’) {
    $this->sendEmailNotification($message, $channel, $notification);
    }
    }

    /**
    * Sends e-mail notification.
    *
    * @param WiseChatMessage $message
    * @param WiseChatChannel $channel
    * @param WiseChatUserNotification $notification
    */
    private function sendEmailNotification($message, $channel, $notification) {
    $timeRange = null; // seconds

    if ($notification->getFrequency() == ‘daily’) {
    $timeRange = 24 * 60 * 60;
    }
    if ($notification->getFrequency() == ‘hourly’) {
    $timeRange = 60 * 60;
    }
    if ($timeRange === null) {
    return;
    }

    if ($this->sentNotificationsDAO->wasNotificationSendForUser($notification->getId(), $channel->getId(), $message->getUserId(), $timeRange)) {
    return;
    }

    $recipientUser = $this->usersDAO->get($message->getRecipientId());
    if ($recipientUser === null) {
    return;
    }

    $channelUser = $this->channelUsersDAO->getActiveByUserIdAndChannelId($recipientUser->getId(), $channel->getId());
    if ($channelUser !== null) {
    return;
    }

    if ($recipientUser->getDataProperty(‘disableNotifications’) === true) {
    return;
    }

    if (!($recipientUser->getWordPressId() > 0)) {
    return;
    }

    $recipientWordPressUser = $this->usersDAO->getWpUserByID($recipientUser->getWordPressId());
    if ($recipientWordPressUser === null) {
    return;
    }

    $sentNotification = new WiseChatSentNotification();
    $sentNotification->setNotificationId($notification->getId());
    $sentNotification->setSentTime(time());
    $sentNotification->setChannelId($channel->getId());
    $sentNotification->setUserId($message->getUserId());
    $this->sentNotificationsDAO->save($sentNotification);

    // send the e-mail:
    $templateData = array(
    ‘${recipient}’ => $recipientWordPressUser->display_name,
    ‘${recipient-email}’ => $recipientWordPressUser->user_email,
    ‘${sender}’ => strip_tags($message->getUserName()),
    ‘${message}’ => $message->getText(),
    ‘${channel}’ => $message->getChannelName(),
    ‘${link}’ => $this->httpRequestService->getReferrerURL()
    );
    $emailSubject = str_replace(array_keys($templateData), array_values($templateData), $notification->getDetails()[‘subject’]);
    $emailBody = str_replace(array_keys($templateData), array_values($templateData), $notification->getDetails()[‘content’]);

    wp_mail($recipientWordPressUser->user_email, $emailSubject, $emailBody);
    }
    }

    #311742
    ivanwancora
    Participant

    Thanks @clickallco but that’s not what we are trying.

    What we need is create in the main menu an option with the hidden group of every member and hide all the others the member not’s in them. Because the only way to access to this groups is thought this links. We don’t need private groups because we don’t want the users can request registration or see the other groups.

    #311557
    shanebp
    Moderator

    You are correct. For a private group try this which uses a different hook:

    function schene_promote_group_member( $user_id, $group_id ) {
        $group_member = new BP_Groups_Member( $user_id, $group_id );
        $group_member->promote( 'admin' );
    }
    add_action( 'groups_membership_accepted', 'schene_promote_group_member', 99, 2 );
    #311539
    Andreas
    Participant

    Good morning shanebp,

    yes, of course I did it exactly the way you described. In the end I also found the reason why it did not work: It does work for public groups, but not for private groups. Is this also the same on your side? And if yes, do you know if there is something to get the same result for private groups?

    sandaap
    Participant

    Today, I tried to install BuddyPress the first time. But I still too stupid to get to running.

    First, I tried the actual stable version 5.2.0 without luck. After this, I tried it with 6.0.0RC2 with the same result.

    My problem is: I don’t find out, how to create new topics or manage groups.

    Is there any special URL doing this?

    WordPress: 4.9.13
    PHP: 7.3.x
    Database: MariaDB 10.4.11
    Theme: Hueman 3.5.3

    In BuddyPress 5.2, the pages for Members, Activity, Activation and Registering were created automatically. In BP 6 not and the Repair Tool does not create them automatically.

    All of these pages are empty for me.

    But inside the AdminBar, I see the “0” and I can use the several private pages.

    How can I configure the groups, where I can open topics and how do I do this?

    Sorry, but it seems I’m too stupid for BP… 🙁

    tuvidigital
    Participant

    Hello, I have a healthcare site in which I would like to make it a “pro” feature for users to be able to colaborators (contributors).

    My default user will be a subscriber
    However I would only like clients and collaborators to be able to message each other (also admins and superadmins ofcourse).

    I saw a simlillar thread about hiding the private message button but it was ID specific, not role specific. I would appreciate specific information as for my request. Also, where should I paste the code? I am not very experienced. Thanks!

    #311285
    Varun Dubey
    Participant

    @onfleekresources

    It can be done with some custom code, or you can also checkout follow plugins.

    1- BuddyPress Private Community Pro plugin that adds a couple of features for admin and it allows admin to select based on user role or member type who can post on activity stream and you can also apply same limits on other BuddyPress features.

    2- You can set some specific members as auto friends to all members, and any activity admin members are going to make will be displayed to all member’s activity page

    #311277
    jmorilla
    Participant

    Hi everyone!
    I have this problem.
    When they write me a private message within my intranet, then an email arrives to my email as I have a message and this is the approximate url
    (https: //…/messages/view/113/)
    Clicking takes me to the page (http: //…../login/)
    And when I login, I will not be redirected to the previous url, but will stay in the home.

    Is there any solution?
    Thanks!!!

    simonlepamplemousse
    Participant

    Hello,

    The site to troubleshoot is: planetanim.fr

    I have had an error for a long time and I apologize if it has already been exposed and corrected. And I apologize for my bad English.

    I use buddyPress and bbPress for forums. For private forums, the bbP Private Groups plugin manages them for many reasons.

    The activity of private forums is displayed in BuddyPress activity streams whether users are connected or not, whether they are members of private forums or not. And it’s problematic. I even had to wait until I could solve the problem to suspend the display of the activity stream. Which is a shame.

    If you have an idea, please share it with me.

    shanebp
    Moderator

    You cannot get roles from just the user id.
    Try:

    function remove_private_message_button( $button ) {
    
    	$user_id = bp_loggedin_user_id();
    	$user = get_userdata( $user_id );
            $user_roles = $user->roles;
    	$allowed_ids = array( 23, 6, 25 );
    
    	if ( !empty( $user_roles ) && is_array( $user_roles ) ) {
    
    		if ( in_array( 'subscriber', $user_roles, true ) ) {
    
    			$button = '';
    			
    		} elseif ( in_array( 'contributor', $user_roles, true ) ) {
    				
    			if ( in_array( $user_id, $allowed_ids, true ) ) {
    				return $button;	
    			}
    
    		} 
    
    	}
    
    	return $button;
    
    }
    add_filter( 'bp_get_send_message_button', 'remove_private_message_button', 1 , 1 );
    simmidhaliwal
    Participant

    I created an action that uses the messages_new_message function (any time a user gets a tag, they automatically receive a private message.)

    Would it be possible to put a border around the message or make the font different? I would like to make these messages stand out a little from the other messages in a users inbox/thread by adding some styling. Below is the code I am using:

    function send_message_to_student_113( $user_id, $tags_applied ) {
    
    $tag_id = wp_fusion()->user->get_tag_id( ‘course tag 1.1.1’ );
    
    if ( in_array( $tag_id, $tags_applied ) ) {
    
    $args = array(
    ‘sender_id’ => 1,
    ‘thread_id’ => false,
    ‘recipients’ => $user_id,
    ‘subject’ => ‘Hello there’,
    ‘content’ => ‘You got a new tag! Congratulations. Please let me know if you need any help!’,
    ‘date_sent’ => bp_core_current_time()
    );
    
    $result = messages_new_message( $args );
    
    }
    }
    add_action( ‘wpf_tags_applied’, ‘send_message_to_student_113’, 10, 2 );

    I am using WordPress 5.3 and I am actually using BuddyBoss which is a fork of Buddypress.

    Thank you! Simmi

    #310972
    simmidhaliwal
    Participant

    Sorry for not listening to the rules! Here is a better version of my previous post –
    I am using WordPress 5.3 and I am actually using a theme called BuddyBoss to implement Buddyboss but that shouldn’t matter for my question.

    So I created a custom function where any time a user gets a tag, they automatically receive a private message. I would like to make these messages stand out a little from the other messages in a users inbox/thread by adding special styling. Would it be possible to put a border around this message? Below is the code I am using:

    Thank you! Simmi

    function send_message_to_student_113( $user_id, $tags_applied ) {
    
    $tag_id = wp_fusion()->user->get_tag_id( ‘course tag 1.1.1’ );
    
    if ( in_array( $tag_id, $tags_applied ) ) {
    
    $args = array(
    ‘sender_id’ => 1,
    ‘thread_id’ => false,
    ‘recipients’ => $user_id,
    ‘subject’ => ‘Hello there’,
    ‘content’ => ‘You got a new tag! Congratulations. Please let me know if you need any help!’,
    ‘date_sent’ => bp_core_current_time()
    );
    
    $result = messages_new_message( $args );
    
    }
    }
    add_action( ‘wpf_tags_applied’, ‘send_message_to_student_113’, 10, 2 );
    #310935
    shanebp
    Moderator

    Another lock-down option is: https://wordpress.org/plugins/bp-simple-private/

    However, if you just need some private pages & categories, then you don’t need BuddyPress at all unless there is some interface aspect that requires profiles.

    If you aren’t using profiles, then there are probably some WP plugins that do what you want.
    Or, the custom WP code to accomplish is quite simple – if you are a WP dev.

    #310859
    alama32
    Participant

    Thanks mercine, it’s work fine, private navigate equal all other users non admin. cool ! 😉
    And, under Activate page, what is the Key ??

    #310858
    @mercime
    Participant

    >> I have the menus “Activate and” register “which point to my home page .. ?? how it is done?


    @alama32
    That’s the default behavior for the register page when you’re logged in. You can see your register page even when you’re logged in by opening a private window. So if you’re using Chrome, open up “New incognito window”; or on Firefox, open up “New Private Window”; or Edge, open up “New InPrivate Window”, etc.

    #310857
    @mercime
    Participant

    >>Yes, I can choose the “Register & Activate pages” that have been created by buddypress, but if I want to view those pages then I will come to both of them on the Homepage …


    @robproce
    That’s the default behavior when you’re logged in. You can see your register page even when you’re logged in by opening a private window. So if you’re using Chrome, open up “New incognito window”; or on Firefox, open up “New Private Window”; or Edge, open up “New InPrivate Window”, etc.

    jbrandsma
    Participant

    I have wordpress version 5.4 and buddypress version 5.1.2. I am using bbpress, youzer, and buddypress to wordpress full sync.

    I had gathered from research that users can private message to other users from the compose screen if they’re not friends, by simply inputting in their username in the input field. But currently the user is only able to send a private message to a friend, rather than any member. How do I open up this functionality so users can find any member in the directory to send a private message?

    #310783
    iamthewebb
    Participant

    I normally open a private browser window when I need to see the site as a logged out user and stay logged in using another tab.

    How does the page look when you have the twentytwenty theme active? Unfortunately as BeTheme is a premium theme I may not be able to help much.

    #310740

    In reply to: Group Photo Upload

    iamthewebb
    Participant

    I just use standard BP on my sites and using the normal wordpress groups users can upload images although when uploading for posts etc they are not private if this is something you are looking for.

    #310687
    peppo90
    Participant

    Hi, how can I disable upload image in private or public messages? Because I don’t have a lot of space available in my site and if the users send a lot of images in a little time I finish my space.
    Thanks

    matwin23
    Participant

    yes, i use this code…

    // ADD SHORTCODE TO SINGLE PRODUCT – PM link
    add_action( ‘woocommerce_share’, ‘enfold_customization_extra_product_content’, 15 );
    function enfold_customization_extra_product_content() {
    echo do_shortcode(“[bp-pm-button]”);
    }

    //////////////////////////////////////////////////////////////////
    // BuddyPress send private message button
    //////////////////////////////////////////////////////////////////

    /**
    * Get a link to send PM to the given User.
    *
    * @param int $user_id user id.
    *
    * @return string
    */
    function buddydev_get_send_private_message_to_user_url( $user_id ) {
    return wp_nonce_url( bp_loggedin_user_domain() . bp_get_messages_slug() . ‘/compose/?r=’ . bp_core_get_username( $user_id ) );
    }

    /**
    * Shortcode [bp-pm-button username=optional_some_user_name]
    *
    * @param array $atts shortcode attributes.
    * @param string $content content.
    *
    * @return string
    */
    function buddydev_private_message_button_shortcode( $atts, $content = ” ) {
    // User is not logged in.
    if ( ! is_user_logged_in() ) {
    return ”;
    }

    $atts = shortcode_atts( array(
    ‘user_id’ => ”,
    ‘username’ => ”,
    ‘label’ => ‘Send this Member a Message’,
    ), $atts );

    $user_id = absint( $atts[‘user_id’] );
    $user_login = $atts[‘username’];

    // if the username is given, override the user id.
    if ( $user_login ) {
    $user = get_user_by( ‘login’, $user_login );
    if ( ! $user ) {
    return ”;
    }
    $user_id = $user->ID;
    }

    if ( ! $user_id ) {
    if ( ! in_the_loop() ) {
    return ”;
    }

    $user_id = get_the_author_meta(‘ID’ );
    }
    // do not show the PM button for the user, if it is aimed at them.
    if ( bp_loggedin_user_id() === $user_id ) {
    return ”;
    }

    // if we are here, generate the button.
    $button = sprintf(‘%2$s‘, buddydev_get_send_private_message_to_user_url( $user_id ), $atts[‘label’] );

    return $button . $content;
    }

    add_shortcode( ‘bp-pm-button’, ‘buddydev_private_message_button_shortcode’ );

    calliesens
    Participant

    Hello, I would like to do the following:

    1. Disable friends function: I do not wish my members to contact/interact with each other privately
    2. Groups:
    a. Only admins who are given permissions can setup groups and they can invite any member in the member directory to the group (does the admin have to add every new member as friend in order to do this?)
    b. Members in the group can communicate with each other within the group with @mentions but they cannot add each other as friends, message each other privately or send invites to invite others into the group

    Is the above possible? Any help is greatly appreciated! Thank you very much!

    #310339
    parthiba
    Participant

    Mirrorfly , a white-label chat solution to build instant messaging app for any business with features & customizations that runs on Android, iOS, & Web.

    Mirrorfly SaaP Solution – One Time Payment & customized Solutions
    Messaging & Collaboration – Connect, Chat & Collaborate Beyond Platforms

    Private 1-to-1 Chat
    Push Notifications
    Message Broadcast Option
    Cross-platform Messaging

    Voice Communication – Make Real-time Conversations Anytime, Anywhere
    1-to-1 Call
    Conference Calling
    Voice Call Recording
    Cross-platform Calling
    Cross-platform Calling
    Interactive Voice Response (IVR)

    Video Communication -Explore HD Video Experience You Demand
    One-to-one
    Multi-party
    Video Call Recording
    Screen Sharing
    Picture-In-Picture
    Whiteboard

    Explore more features here

Viewing 25 results - 251 through 275 (of 3,498 total)
Skip to toolbar