BuddyDev

Search

Replies

  • Participant
    Level: Initiated
    Posts: 11

    Its ok. I figured out some temporary code until you update. Thank you.

  • Participant
    Level: Initiated
    Posts: 11

    Ok, I assumed that was what was meant by “logout user on deactivation”. I did not know that the user him/herself would be the one to have to deactivate in order to logout. Can I expect this update to the plugin in the near future? I hate to have to edit the plugin but for now I will mess around with WP_Session_Tokens::get_instance($user_id) and destroy_all and see if I can fiddle something for myself

  • Participant
    Level: Initiated
    Posts: 11

    I am logged in as admin and I am trying to deactivate a user who is logged into the site from a different IP. Still I cannot log that user out

  • Participant
    Level: Initiated
    Posts: 11

    Hi Brajesh. Sorry for the late reply. To answer your questions, it is not a multisite, I do not have any caching plugin. The way I am using it is to suspend users, so I do not allow uses to deactivate their own account. However, what happens is the user gets suspended but they are still allowed to navigate buddypress with limited access. The issue seems to be with this line of code.

    
    		$is_manager = bp_account_deactivator()->current_user_can_change_account_status();
    		$logged_out = false;
    		if ( ! $is_manager && $deactivator->get_option( 'logout-on-deactivation' ) ) {
    			wp_logout();
    			$logged_out = true;
    		}

    I noticed that if I get rid of the conditional statement, and just allow wp_logout(), the user that gets logged out is the admin and not the blocked user.

  • Participant
    Level: Initiated
    Posts: 11
    David on in reply to: Default search based on profile fields? #11052

    Hi Brajesh. Awaiting your reply. Thank you.

  • Participant
    Level: Initiated
    Posts: 11
    David on in reply to: Default search based on profile fields? #11020

    Hi Brajesh. Thank you for the reply. If a user will click on a button which brings to the members page (i.e. http://www.yoursite.com/members/), then when the page loads, fields will automatically be populated and a default search will be completed. That way, the url will most likely show like http://www.yoursite.com/members/?field_6=Teacher&field_8=apple for example. Does that make sense?

  • Participant
    Level: Initiated
    Posts: 11
    David on in reply to: Put a limit on message notifications? #7094

    Hi Brajesh. That is exactly correct. And the limit should be on both notifications and email, with a maximum of 1 of each until the message is read.

  • Participant
    Level: Initiated
    Posts: 11
    David on in reply to: [Resolved] Single message thread per user? #7013

    I was able to complete this. Thank you very much for the code you provided.

  • Participant
    Level: Initiated
    Posts: 11
    David on in reply to: [Resolved] Single message thread per user? #6982

    When you mean you’re not getting the changes there, you mean in regards to the bp message ajax plugin?

    I appreciate you sending that piece of code above. A few questions, I have so far though. Are the variables $user_id and $other_id already declared or do I have to declare it? Also do I then return the thread_ids into my other function to check to see if a thread exists? I am sorry but I am still relatively amateur(In my opinion) when it comes to programming.

    See my pastebin.
    http://pastebin.com/Tu5Ct75J

    Thank you as always.

  • Participant
    Level: Initiated
    Posts: 11
    David on in reply to: [Resolved] Single message thread per user? #6973

    Hi Brajesh,

    This is what I have so far. Can you tell me if I am on the right path?

    http://pastebin.com/nKrbmRnH

    I am having trouble figuring out how I would check to see if there are any current threads associated with the recipients, and if so, get that current thread_id

    Another problem I am having is that I use the Buddymessageux plugin, which ajaxifies the messaging so that I don’t have to go to the compose page. Problem is, I tried hooking into one of the actions (wp) of that plugin that creates the message and my code does nothing

    If I disable the plugin, and hook into the current action as showed in the pastebin link (bp-actions), this code then has an effect. Problem is, I no longer have the ajax messaging and now I need to re-enable the compose page in order to send the message.

    Do you have any thoughts on this? Thank you very much for your help. By the way, is there any way I can donate to you for your time?