• I’m Using:
      WP 3.0.1
      BP 1.2.5.2
      BuddyPress Followers 1.0

    now lets come to the point … there is an issue with notification system, and I have found the same in Buddypress.org too …

    Suppose there are two person ; Person A and Person B

    Person B wants to follow Person A , hence click on follow , a notification is sent to Person A , that somebody is following Person A

    In the mean time Person A is not logged in to buddypress so didn’t got the notification …. but in this due course Person B has stopped following Person A ….

    Thing should happen is the notofication to Person A become null and void and should be shown in Person A‘s Profile….

    What happening is ! Person A is still getting the notification and as there is nobody following Person A , the

      notification stays for ever and naggs the user

    This is a very good plugin and I think only this

      notification issue is becoming an obstacle to use it in live buddypress website

    Hope a solution canbe found very soon.
    Many many Thanks to the developer …

    .

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter anindyaray

    (@anindyaray)

    and also after un-installing the plugin , database entries are not getting deleted

    haxxxton

    (@haxxxton)

    sorry to revive an old thread,

    but has anyone found a solution to this?

    I think the key lies in doing a $wpdb-> call and delete the notification when Person A clicks the unfollow link,

    however finding where the function that handles the link is proving to be extremely difficult.

    It appears AJAX loads some of the follow data in bp-follow.js, but given this is javascript it isnt very helpful for implementing a PHP call

    the URL link that actions the unfollow is of the format:
    http://MYDOMAIN.com/members/PERSON-B/followers/stop/?_wpnonce=d709dd4867

    any help with this would be great

    haxxxton

    (@haxxxton)

    I just managed to fix this issue 😀 HUZZAH!!

    you just have to add some code to bp-follow.php

    find the function called bp_follow_stop_following.. for me it is near line 495.

    add the following line

    unnotify();

    above the line

    do_action( 'bp_follow_stop_following', &$follow );

    then paste the following under the bp_follow_stop_following function

    function unnotify(){
    	global $bp;
    	global $wpdb;
    	$user_id = $bp->displayed_user->id;
    	$item_id = $bp->loggedin_user->id;
    	$notification = $wpdb->get_col("SELECT id FROM <code>wp_bp_notifications</code> WHERE component_name='follow' AND item_id='".$item_id."' AND user_id ='".$user_id."'");
    	if($notification[0] == ""){
    
    	}else{
    		$wpdb->query( $wpdb->prepare("DELETE FROM <code>wp_bp_notifications</code> WHERE id = '".$notification[0]."'"));
    	}	
    
    	bp_core_redirect( wp_get_referer() );
    }

    This now removes unread notifications about that follow from the followee when the user unfollows him..

    haxxxton (to the rescue)

    sorry to go bit off topic.. is there a way apart from following user i can add follow to my post tags or categories..so that whenever a post in added in say tag xyz user get a notfication or activity in his profile..

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Plugin: BuddyPress Followers] Notification Issue’ is closed to new replies.