Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'comment notification'

Viewing 25 results - 126 through 150 (of 329 total)
  • Author
    Search Results
  • #236652
    danbp
    Participant

    Post comments are outside of the user notification. @mention scope is handling site and user activities. A post is also an activity, but @mention in it is not an activity. It’s just a link to a profile in a post.

    When you go to message settings on your profile, you can see the whole items covered by mention and email notification. Blog post are not included.

    #236646
    briggsy326
    Participant

    @xander206 Thanks for the response. 🙂

    I had a quick look at the link your provided and I’m not really sure it’s quite what I am looking for.

    At present there is already a ‘notifications’ area on the profile page (and on the ‘admin’ bar at the top of the page) and notifications for @ mentions on the profile itself are working and also notifications for friend requests are working too.

    The only thing that isn’t working is notifications for @ mentions on comments on posts. Whenever someone replies to a comment on a post and starts it with @ username it is being linked to their profile but it is not sending a notification to that person that they have been mentioned.

    Cheers

    aljo1985
    Participant

    Okay so I realised that it would only send the activity to stream when you have the email option checked. I also noticed that upon doing that you post 2 pieces of information into the database that are exactly the same.. Well they are not structured the same but the information holds the same data.

    This is inside bp_groups_groupmeta and bp_activity
    So I have optimized my code to remove duplicate data, well just removed it from posting into groupsmeta really, as it doesn’t need to be in there… Maybe you can optimize your code to post the action in activity only and read from there, rather than have it posted in both. The system is great, don’t get me wrong I am just making suggestions.

    So I have removed one of your functions on remove action and copied it into my own function with edits to that function. I have added 2 extra fields, drop down boxs to be exact.

    Here is my code with a lot of comments as I was trying out many different things, then decided I don’t want it to do that lol. EDIT

    <?php
    // Add custom group fields.
    // Removed the default add activity stream. file /public_html/wp-content/plugins/buddypress/bp-groups/bp-groups-activity.php for reference.
    remove_action( 'groups_details_updated', 'bp_groups_group_details_updated_add_activity' );
    // On group update.
    add_action( 'groups_details_updated', 'group_details_update', 10, 3 );
    // Updated group details.
    // Updated group details.
    function group_details_update( $group_id, $old_group, $notify_members ) {
    	global $bp, $wpdb;
    	// Custom fields.
    	$plain_fields = array(
    		'server',
    		'country'
    		//'activity'
    	);
    	foreach( $plain_fields as $field ) {
    		$key = 'group-' . $field;
    		$metakey = 'h1z1_' . $field;
    		if ( isset( $_POST[$key] ) ) {
    			$value = $_POST[$key];
    			
    			// Do they want the update notification posted on their activity stream?
    			/*if ($value == '1')
    				$post_activity = true;
    			*/
    			//Make sure they selected an item from the required dropdown boxs.
    			if ($value == 'null')
    				return bp_core_add_message( __( 'There was an error updating group details. Please try again.', 'buddypress' ), 'error' );
    			else {
    				// changed1 is empty by default, not declared. If empty, get groupmeta.
    				if (empty($changed))
    					$changed = groups_get_groupmeta( $group_id, $metakey );
    				//if groupmeta(old value) == posted value changed is empty again, so we can check the next custom field to see if that also has the same old value.
    				if ($changed == $value)
    					$changed = '';
    				else
    					groups_update_groupmeta( $group_id, $metakey, $value );
    			}
     		}
    	}
    	// Optional removed checkbox for now.. Might use later
    	/*if ($post_activity == false)
    		return false;
    	*/
    	// Taken from /public_html/wp-content/plugins/buddypress/bp-groups/bp-groups-activity.php
    	// We removed the email notification check so that it will post an activity stream regardless.
    	// Bail if Activity is not active.
    	if ( ! bp_is_active( 'activity' ) )
    		return false;
    
    	if ( ! isset( $old_group->name ) || ! isset( $old_group->description ) )
    		return false;
    
    	// If the admin has opted not to notify members, don't post an activity item either
    	// Removed, I want updated posted if it sends and email or not.
    	/*if ( empty( $notify_members ) ) {
    		return;
    	}*/
    
    	$group = groups_get_group( array(
    		'group_id' => $group_id,
    	) );
    
    	/*
    	 * Store the changed data, which will be used to generate the activity
    	 * action. Since we haven't yet created the activity item, we store the
    	 * old group data in groupmeta, keyed by the timestamp that we'll put
    	 * on the activity item.
    	 */
    	
    	if ( $group->name !== $old_group->name || $group->description !== $old_group->description )
    		$changed = 'changed';
    
    	// If there are no changes, don't post an activity item.
    	if ( empty( $changed ) )
    		return;
    
    	$time = bp_core_current_time();
    	// Don't want a long description of what has been changed inside the details. Also reduces information posted in groupmeta table.
    	//groups_update_groupmeta( $group_id, 'updated_details_' . $time, $changed );
    	
    	// And finally, update groups last activity.. Currently doesn't in standard.
    	groups_update_groupmeta( $group_id, 'last_activity', $time );
    	
    	// Since we have removed the information from meta, we will record it directly into action on activity..
    	// You do not need the same information recorded twice in the database. This needs optimizing. Hence removing update groupmeta..
    	/*
    	$user_link = bp_core_get_userlink( bp_loggedin_user_id() );
    	$group_link = '<a href="' . esc_url( bp_get_group_permalink( $group ) ) . '">' . esc_html( $group->name ) . '</a>';
    	$action = sprintf( __( '%1$s changed the description of the group %2$s from "%3$s" to "%4$s"', 'buddypress' ), $user_link, $group_link, esc_html( $changed['description']['old'] ), esc_html( $changed['description']['new'] ) );
    	*/
    	// Record in activity streams.
    	return groups_record_activity( array(
    		'type'          => 'group_details_updated',
    		'item_id'       => $group_id,
    		'user_id'       => bp_loggedin_user_id(),
    		'recorded_time' => $time,
    	) );
    }

    If there is bugs in any code, I will find them and fix them.. That’s one of the downsides to being a perfectionist..

    I have not fixed the

    A few bugs I have found.

    From the first post yet, but will be doing after I have had my dinner 🙂
    My idea is to have a notification saying that the user has left the group when they leave/kicked/banned/ obviously if its after the 5 minutes mark lol.

    giuseppecuttone
    Participant

    Hi @r-a-y
    I have solved the problems with notifications toolbar derived from comments and groups.
    The problem was that I used no plugin in order to send notifications… I’m a little silly … 😉
    But now I continue with the problem about notifications derived from FORUM.
    I have used three differents plugins but I continue with the same problem…
    This is a bbPress problem… I understand that, but I have seen that in this web page (https://buddypress.org) notifications run very well, so my question is:
    What is the plugin used in this page (https://buddypress.org) in order to send forum notifications in administration toolbar?
    Can you reply me? Or can you indicate who can know that?
    Thank’s very much.

    #235221
    giuseppecuttone
    Participant

    Hi @alexterchum and @sbrajesh
    I think Alex is right.
    The other BuddyPress Notifications disappears when user visit the page.
    Also the others notifications generated with the others plugins that sbrajesh has developped (BP Group Activities Notifier and BuddyPress Activity Comment Notifier) run well.
    For example if the USER A send a message to USER B, USER B receive one notification.
    When USER B visit the page whin the message (http://URLWEBSITE/members/USER-NAME/messages/view/xx/) – clicking in the notification or by other way… – the notification will be dissapear.
    Also in the page http://URLWEBSITE/members/USER-NAME/notifications/, when user visit the page with the message, the message automatically will go to the section UNREAD and it is not necessary that the user must to mark as READ the message in order to dissapear the notification.

    I have the same problem with FORUM notification (using https://wordpress.org/support/plugin/bp-forum-notifier).

    sbrajesh, can you solve the problem in the plugin “BuddyPress Notify Post Author on Blog Comment”?

    Thank’s very much

    #234525
    rosyteddy
    Participant

    @henrywright

    Interface or UI
    very lively, fresh and dedicated. Since this is qualitative, imho, you can test any bp site and ello-co

    Discover feature
    and from there you can have “Friend” or “Noise” and the very easy switching between the two

    Privacy features
    Muting prevents further email notifications from a user and removes their past activity from your feed. The user is still able to follow you and can still comment on your posts, but you will not receive any notifications.
    Blocking mutes a user, and disables them from viewing your profile and posts.
    BP do not have Blocking, and the premium plugin that is there probably no longer works

    Excellent Media Support well integrated
    In BP, its confusing : WP has its own media repo for the user, again BP plugins store media elsewhere

    These are something that come just top off my head. You can see some more here https://ello.co/wtf/post/featurelist Its not to say Ello is better or BP is better : its just sharing something new with you all – Ello is not a script we can use, BP is a script we can use and customize.

    r-a-y
    Keymaster

    We’re looking to improve the invite process for BuddyPress 2.3.

    I’m going to ping @dcavins, as he will be implementing the invite improvements, so he’s aware of this.

    Just to answer your questions:

    Notification in the profile window’s (there are 3 notifications: message (1) – friends (1) – but in GROUPS there is no notification).

    The “Groups > No Pending Invites” nav item is for invites you have requested. Not invites that are pending for the entire group.

    The user (A) has posted in a group wall’s and the user (B) has done a comment.
    The user (A) hasn’t received notification neither admin toolbar or administration profile windows.

    Currently, notifications do not occur for activity comments. We’ll likely add this enhancement into core eventually, but for now, you’ll have to use a plugin for this:

    BuddyPress Activity Comment Notifier

    The user (A) has opened a forum in a grup. The user (B) has done a comment.
    The user (A) has received notification in the administratio toolbar. But when the user (A) has done a comment the user (B) don’t has received the notification.

    How did user A reply to user B? On the group activity homepage or on the actual group forum topic? If user A replied on the group forum topic, then this sounds like an issue with bbPress, not BuddyPress.

    #231433
    danbp
    Participant

    Hi,

    you’ve already asked for this in the past !

    https://codex.buddypress.org/member-guide/notifications/

    By default, each member can activate/deactivate notification (under Your Profile > settings > email)
    Reference: bp-activity/bp-activity-screens.php

    Or see this plugin.

    #230350
    Paul Bursnall
    Participant

    @sebacar Maybe the documentation quoted above could be written better. You’ll notice comment replies do trigger a front-end notification if you use the @handle of the member you’re replying to.

    #230308
    Paul Bursnall
    Participant

    @sebacar @mercime Hi Sebastien, from looking at replies to your Trac ticket, I think something is being lost in translation between ourselves and the devs.

    To quote the official documentation :

    Notifications are a central aspect of the user experience on a BuddyPress site. By default new notifications are displayed in the admin bar profile menu, right next to the navigation menus, some themes even integrate the notification counter in other places (like in the header or sidebar of a page).

    Notifications are sent out to your community members as soon as one of the following things happen:

    Activity

    A member mentions you in an update @username
    A member replies to an update or comment you’ve posted

    The activity in bold above definitely stopped triggering notifications on 3 different sites I was testing, where it had previously generated a notification (probably 4 months+ consistently). Quite simply, that notification trigger stopped working. This should not be a new feature, it was already there.

    #230051
    tim_marston
    Participant

    Thanks @henrywright

    Here is the list:

    Admin Tweaks
    Advanced Excerpt
    Antispam Bee
    bbPress
    Bowe Codes
    BP Auto Activate Autologin Redirect To Profile On Signup
    Bp Clear Notifications
    BP Group Activities Notifier
    Broken Link Checker
    BuddyBlock
    BuddyPress
    Buddy Press Activity Ads
    BuddyPress Activity as Wire
    BuddyPress Activity Comment Notifier
    BuddyPress Activity Privacy
    BuddyPress Block Activity Stream Types
    BuddyPress Live Notification
    BuddyPress Profile Visibility Manager
    BuddyPress Security Check
    BuddyPress Usernames Only
    Delete Expired Transients
    Duplicator
    Email Login
    Facebook Like User Activity Stream For BuddyPress
    Google Analytics +
    Imsanity
    Infinite SEO
    Insert Headers and Footers
    Mailjet for WordPress
    Menu Items Visibility Control
    OPcache Dashboard
    Post Voting
    Pretty Link Lite
    Query Monitor
    Random Banner
    rtMedia for WordPress, BuddyPress and bbPress
    rtMedia Pro
    s2Member Framework
    SearchWP
    SearchWP bbPress Integration
    Social Likes
    Subscribe To Comments
    User Activity
    Wordfence Security
    WordPress FAQ Manager
    WP-DBManager
    WP-Memory-Usage
    wp-Monalisa
    WPBakery Visual Composer
    WP Better Emails
    WP External Links
    WP Maintenance Mode
    WPMU DEV Dashboard
    WP Widget Cache

    #229862
    Brent Havill
    Participant

    Hi Henry

    I went to ‘plugins’/buddypress/settings, and found the following (I note that “account settings” is not ticked – could this be it?)
    I have bolded the ones that are ticked currently.

    Settings:

    Component Description
    Component Description
    Extended Profiles Customize your community with fully editable profile fields that allow your users to describe themselves.
    Account Settings Allow your users to modify their account and notification settings directly from within their profiles.
    Friend Connections Let your users make connections so they can track the activity of others and focus on the people they care about the most.
    Private Messaging Allow your users to talk to each other directly and in private. Not just limited to one-on-one discussions, messages can be sent between any number of members.
    Activity Streams Global, personal, and group activity streams with threaded commenting, direct posting, favoriting, and @mentions, all with full RSS feed and email notification support.
    Notifications Notify members of relevant activity with a toolbar bubble and/or via email, and allow them to customize their notification settings.
    User Groups Groups allow your users to organize themselves into specific public, private or hidden sections with separate activity streams and member listings.
    Site Tracking Record activity for new posts and comments from your site.
    BuddyPress Core It‘s what makes time travel BuddyPress possible!
    Community Members Everything in a BuddyPress community revolves around its members.

    #228998
    jbird
    Participant

    Ok, so I just tried again with the Twenty Twelve theme and every single plugin (including Akismet) deactivated, except for Buddypress.

    While logged in under a test user account, I left a new comment on a blog post, and still no comments showing up in the activity stream at all. (It shows up under the post itself, and I’m getting new comment notifications to my admin email, so the general commenting is working…just not in conjunction with the Activity stream.)

    *sigh*

    Are there any other settings elsewhere in WP that might be causing this? (I just LOVE when I am the one to discover problems that no one can seem to solve 🙂

    Thanks so much for your advice!!

    #228794
    mcpeanut
    Participant

    @sbaglia i really dont have a clue about this but ive just noticed a recent update on a plugin that adds seperate social networking functions to wordpress that i have been watching for a while, now the idea i had a while ago was wondering if this plugin could infact be ran alongside buddypress just for the comment notifications within wordpress, meaning i was wondering if all other notifications and workings of this other plugin could be disabled and used just for this one specific task, this way users would have a seperate notification system for blog and custom post comments, i really dont know as i have not messed around with them together but i know that this plugin does achieve what we want but seperately to buddypress, maybee you want to have a mess with the idea i had? i just dont have time at the minute and dont know if it will work well with buddypress running too, the plugin is here https://wordpress.org/plugins/wp-notifications/

    #228792
    mcpeanut
    Participant

    @sbaglia i too would like to achieve this but have been so busy with doing other things that i have not even looked at how or if this could be done yet, so i +1 this request if anyone has any info on how to do this? it would be awesome if users received notification on blog post comments or for me especially custom post type comments. to me this would infact give complete social network functioning throughout my entire site this way and not just on the buddypress pages.

    #190941
    aghajoon
    Participant

    this code work for me but java script not work and when user favorite comment user can’t remove notification help me

    define("BP_FAVORITE_NOTIFIER_SLUG","fa_notification");
    
        function bp_favorite_setup_globals() {	
    	global $bp, $current_blog;
        $bp->bp_favorite=new stdClass();
        $bp->bp_favorite->id = 'bp_favorite';
        $bp->bp_favorite->slug = BP_FAVORITE_NOTIFIER_SLUG;
        $bp->bp_favorite->notification_callback = 'bp_favorite_format_notifications';//show the notification   
        $bp->active_components[$bp->bp_favorite->id] = $bp->bp_favorite->id;
    			
                do_action( 'bp_favorite_setup_globals' );
        }
                add_action( 'bp_setup_globals', 'bp_favorite_setup_globals' );
         
    
    function bp_favorite_format_notifications(  $action, $activity_id, $secondary_item_id, $total_items,$format='string'  ) { 
    $action_checker = explode('_', $action);
    $activities = bp_activity_get_specific( array( 'activity_ids' => $activity_id, 'display_comments' => true) );
    	$glue = '';
    	$user_names = array();
    
    	$users = find_favorite_involved_persons($activity_id, $action);
    	$total_user = $count = count($users);
    
    	if($count > 2) {
    		$users = array_slice($users, $count - 2);
    		$count = $count - 2;
    		$glue = ", ";
    	} else if($total_user == 2) {
    		$glue = " and ";
    	}
    
    	foreach((array)$users as $user_id) {
    		$user_names[] = bp_core_get_user_displayname($user_id);
    	}
    
    	if(!empty($user_names)) {
    		$favoriting_users = join($glue, $user_names);
    	}
    
    	switch ( $action ) {
    		case 'new_bp_favorite_'.$activity_id:
    			if($total_user > 2) {
    				$text = $favoriting_users.' and '.$count.' liked: '.substr($activities["activities"][0]->content,0,32).'...';
    			} else {
    				$text = $favoriting_users." like: ".substr($activities["activities"][0]->content,0,32)."...";
    			}
    		break;
    	}
    	$url = '<div id="'.$action.'"class="notification"><a href="#" class="social-delete" onclick="deleteAjaxNotification(\''.$action.'\',\''.$activity_id.'\', \''.admin_url( 'admin-ajax.php' ).'\'); return false;">x</a><span class="social-loader"></span></div>';
    	$link = favorite_activity_get_permalink( $activity_id );
    
    	if($format=='string') {
    		return apply_filters( 'bp_activity_multiple_favorite_notifications', '<a href="' . $link. '">' . $text . '</a>'. $url .'' ,$users, $total_user, $count, $glue, $link );
    	} else {
    		return array(
    			'link' => $link,
    			'text' => $text
    		);
    	}
    	return false;
    
    }
    function find_favorite_involved_persons($activity_id, $action) {
    	global $bp,$wpdb;
    	$table = $wpdb->prefix . 'bp_notifications';
    	return $wpdb->get_col($wpdb->prepare("select DISTINCT(secondary_item_id) from {$table} where item_id=%d and secondary_item_id!=%d and component_action = %s",$activity_id,$bp->loggedin_user->id, $action));
    }
    function favorite_activity_get_permalink( $activity_id, $activity_obj = false ) {
    	global $bp;
    
    	if ( !$activity_obj )
    		$activity_obj = new BP_Activity_Activity( $activity_id );
                        
    		if ( 'activity_comment' == $activity_obj->type )
    			$link = bp_get_activity_directory_permalink(). 'p/' . $activity_obj->item_id . '/';
    		else
    			$link = bp_get_activity_directory_permalink() . 'p/' . $activity_obj->id . '/';
    
    	return apply_filters( 'ac_notifier_activity_get_permalink', $link );
    
    }
    
    function favorite_notifier_remove_notification($activity ,$has_access){
           global $bp;
           if($has_access)		       
    	   bp_core_delete_notifications_for_user_by_type( $bp->loggedin_user->id, $bp->bp_favorite->id, 'new_bp_favorite_'.$activity->id );
    	}
    add_action("bp_activity_screen_single_activity_permalink","favorite_notifier_remove_notification", 10,2);
    
    function favorite_notification( $activity_id){  
                       global $bp;                 
    	               $activities = bp_activity_get_specific( array( 'activity_ids' => $activity_id, 'display_comments' => true) );
    				   $author_id = $activities['activities'][0]->user_id;
                       $user_id =  bp_loggedin_user_id();
    	// if favoriting own activity, dont send notification
    	if( $user_id == $author_id ) {
    		return false;
    	}
    				   if ( bp_is_active( 'notifications' ) ) {
    		bp_notifications_add_notification( array(
    			'user_id'           => $author_id,
    			'item_id'           => $activity_id,
    			'secondary_item_id' => $user_id,
    			'component_name'    => $bp->bp_favorite->id,
    			'component_action'  => 'new_bp_favorite_'.$activity_id,
    			'date_notified'     => bp_core_current_time(),
    			'is_new'            => 1,
    		) );
    	}				
    }
    add_action("bp_activity_add_user_favorite","favorite_notification", 10, 2);
    
    function deleteAjaxNotification(){
        global $bp;        
        bp_core_delete_notifications_by_item_id ($bp->loggedin_user->id, $bp->bp_favorite->id, 'new_bp_favorite_'.$activity->id);     
        die();        
    }	
    add_action('wp_ajax_deleteAjaxNotification', 'deleteAjaxNotification' ); 
    
    function bp_like_add_like_action() {
    global $bp, $activities_template; 
    	 if ( bp_activity_can_favorite() ) : 
    		
    				$my_fav_count = bp_activity_get_meta( bp_get_activity_comment_id(), 'favorite_count' );
    				
    				$my_fav_count = "<span>".$my_fav_count."</span>";
    				
    				$is_favorite = apply_filters( 'bp_get_activity_is_favorite', in_array( bp_get_activity_comment_id(), $activities_template->my_favs ) );
    		
    
    			 if ( !$is_favorite ) : ?>
    
    				<a href="<?php echo apply_filters( 'bp_get_activity_favorite_link', wp_nonce_url( home_url( bp_get_activity_root_slug() . '/favorite/' . bp_get_activity_comment_id() . '/' ), 'mark_favorite' ) ); ?>" class="tooltip-trigger fav bp-secondary-action bp-primary-action" title="<?php _e( 'Favorite', 'buddypress' ); ?>" style="position:relative;"><?php _e( 'Favorite', 'buddypress' ); ?><?php echo $my_fav_count; ?></a>
    
    			<?php else : ?>
    
    				<a href="<?php echo apply_filters( 'bp_get_activity_favorite_link', wp_nonce_url( home_url( bp_get_activity_root_slug() . '/favorite/' . bp_get_activity_comment_id() . '/' ), 'mark_favorite' ) ); ?>" class="tooltip-trigger unfav bp-secondary-action bp-primary-action" title="<?php _e( 'Remove Favorite', 'buddypress' ); ?>" style="position:relative;"><?php _e( 'Remove Favorite', 'buddypress' ); ?><?php echo $my_fav_count; ?></a>
    
    			<?php endif; 
    
    		 endif; 
    }
    add_filter( 'bp_activity_comment_options' , 'bp_like_add_like_action', 1000 );
    
    

    and java code

    function deleteAjaxNotification(action_id, activity_id, adminUrl){
        jQuery('#'+action_id).children(".social-delete").html("");
        jQuery('#'+action_id ).children(".social-loader").show(); 
    
        jQuery.ajax({
            type: 'post',
            url: adminUrl,
            data: { action: "deleteAjaxNotification", action_id:action_id, activity_id:activity_id },
            success:
            function(data) {
            	jQuery('#'+action_id).parent().hide();
            	
            }
         });  
    }
    r-a-y
    Keymaster
    #183850
    godavid33
    Participant

    Ok, well I had to figure this one out. It’s a bit of a lengthy solution. I’m not going to explain everything, as I can’t for either lack of knowledge or fear of being incorrect. I’ll just give you the code, tell you what it does, and where it goes.

    First, lets add the favorite button to the comments template. Find comment.php (in /activity) and add the code:

    
    		<?php global $activities_template; ?>
    		<?php if ( bp_activity_can_favorite() ) : ?>
    			<?php
    				$my_fav_count = bp_activity_get_meta( bp_get_activity_comment_id(), 'favorite_count' );
    				
    				$my_fav_count = "<span>".$my_fav_count."</span>";
    				
    				$is_favorite = apply_filters( 'bp_get_activity_is_favorite', in_array( bp_get_activity_comment_id(), $activities_template->my_favs ) );
    			?>
    
    			<?php if ( !$is_favorite ) : ?>
    
    				<a href="<?php echo apply_filters( 'bp_get_activity_favorite_link', wp_nonce_url( home_url( bp_get_activity_root_slug() . '/favorite/' . bp_get_activity_comment_id() . '/' ), 'mark_favorite' ) ); ?>" class="tooltip-trigger fav bp-secondary-action bp-primary-action" title="<?php echo god_get_favorited_usernames(bp_get_activity_comment_id()); ?>" style="position:relative;"><?php _e( 'Like', 'buddypress' ); ?><?php echo $my_fav_count; ?></a>
    
    			<?php else : ?>
    
    				<a href="<?php echo apply_filters( 'bp_get_activity_favorite_link', wp_nonce_url( home_url( bp_get_activity_root_slug() . '/favorite/' . bp_get_activity_comment_id() . '/' ), 'mark_favorite' ) ); ?>" class="tooltip-trigger unfav bp-secondary-action bp-primary-action" title="<?php echo god_get_favorited_usernames(bp_get_activity_comment_id()); ?>" style="position:relative;"><?php _e( 'Unlike', 'buddypress' ); ?><?php echo $my_fav_count; ?></a>
    
    			<?php endif; ?>
    
    		<?php endif; ?>	
    

    This code simply adds the buttons, and gets all the necessary info and variables.

    Then, you’re going to need to modify the buddypress javascript. I personally modified both global.js and buddypress.js (through overriding in my template, which is a topic for a whole other thread), though I might be wrong in this. At any rate, look for the line (around 264 in buddypress.js):

    
    var parent = target.closest('.activity-item');
    

    and change it to

    
    var parent = target.closest('li');
    

    The reason we changed this line is so that our custom favorite button doesn’t default to grabbing the top level activity id. Now you can actually favorite comments!

    But wouldn’t it be nice if the user received a notification when someone favorited their activity? Add this bad boy to functions.php

    
    
    add_action("bp_activity_add_user_favorite","favorite_notification", 10, 2);
    
    function favorite_notification( $activity_id, $user_id = 0){
    	// By type and item_id
    	if($user_id != $activities["activities"][0]->user_id){
    		$activities = bp_activity_get_specific( array( 'activity_ids' => $activity_id, 'display_comments' => true) );
    		
    		bp_core_add_notification( $activity_id, $activities["activities"][0]->user_id, "notifier", bp_core_get_username(bp_loggedin_user_id())." liked: '".substr($activities["activities"][0]->content,0,20)."...'", $activity_id ) ;		
    	}
    }
    

    Hope this helped someone. It mostly works for me.

    #182957
    godavid33
    Participant

    Bumping is usually when a topic has not been solved, but an answer is still needed (at least that has been my experience in every forum I’ve ever been in).

    Yes, buddypress natively produces notifications for most things. I have never natively gotten a notification for activity comments/replies, and this is what I’m trying to accomplish (as well as notifications for favorites), and I can add the notification but I need to know how to add a URL with it as well.

    #182937
    julianprice
    Participant

    @godavid33 Just thought I would comment because you bumped your post. What I understanding bumping a post shows topics have been respond too.

    Unfortunately, I am unable to help you because completely out of beginner knowledge but I did go back & look at all your post on the forum. I am trying to understand the logic in all the customization when BuddyPress natively provides notifications.

    #181951
    OrlandoDS
    Participant

    posting another comment with email notifications enabled…

    r-a-y
    Keymaster

    1. This is not a bug. We have never supported screen notifications for activity comments in core. There is already a ticket for this – https://buddypress.trac.wordpress.org/ticket/5395.

    2. The main activity directory doesn’t show activity comments as separate entries by default because it will clutter up the stream. This is intentional, but since people will be using activity comments more, this might be a good time to revisit this.

    Here’s a quick plugin to force the activity stream to always show activity comments as separate entries:
    https://gist.github.com/r-a-y/10937509

    3. Good idea. Will add an enhancement ticket for this for v2.1.

    #181368
    marcusyong
    Participant

    Very amazing we find the 2.0 rc1 ‘s launching. there three question on new version:
    1, Problems on post comment’s notification, when we comment on a post or a post’s comment, it create a comment_activity replying to the new_blog_post activity(item_id) and activity_comment(secondary_item_id), it essentially need to create a notification to the author whom it replying;

    2, Problems on main activity-steam loop. in previous version, when a comment creates under a post, it create a new_blog_comment,and this activity can appears in main activity loop. but at present, when leaving a comment under a post, it only create a activity_comment under the new_blog_post activity, don’t appears in main activity-loop. it’s really not good!

    3, Problems about the comment_activity formation, in previous version when leaving a comment, it create a new_blog_comment activity which include the original post title and url. at present version, the comment_activity don’t bring above information, I think it not a good method.

    #179613
    colabsadmin
    Participant

    – add collapsing of activity comment replies

    – ability to manage notifications (notification bubble). turn off/on individual events AND mass delete and filtering of notification table located in your profile. Deleting one at a time is painful.

    #179181
    Duke Taber
    Participant

    Ok I just read modernloopers list of questions so I want to make this as clear as possible. First this problem is not a plugin problem. I disabled and deleted all and it didn’t fix the problem. I also tried a different theme and it didn’t fix the problem so it is not a theme problem. TJ at Buddyboss tried valiantly to figure out the problem to no avail.

    Here are the questions that modernlooper wanted answered.

    Please try to supply answers to the following questions.

    1. Which version of WordPress are you running? 3.81

    2. Did you install WordPress as a directory or subdomain install? directory

    3. If a directory install, is it in root or in a subdirectory? root

    4. Did you upgrade from a previous version of WordPress? If so, from which version? every one for the last year

    5. Was WordPress functioning properly before installing/upgrading BuddyPress (BP)? e.g. permalinks, creating a new post, commenting. Yes

    6. Which version of BP are you running? 1.92

    7. Did you upgraded from a previous version of BP? If so, from which version? Every one for the last year until 1.9 and then it broke. I just went back to my backup and waited. Upgraded to 1.92 and it is still broken. Went through all the normal troubleshooting processes until figuring out it was the notifications that is causing the error.

    8. Do you have any plugins other than BuddyPress installed and activated? If so, which ones?
    Ads Manager WP/BB
    Akismet
    BBpress
    BB Force Profile
    BuddyPress Tiny group chat
    BuddyPress Links
    Easy Album
    Facebook Friends Inviter
    IFlyChat
    Invite Anyone
    Social Login
    Wanguard

    9. Are you using the standard BuddyPress themes or customized themes? BuddyBoss

    10. Have you modified the core files in any way? No

    11. Do you have any custom functions in bp-custom.php? No, or at least none I am aware of that was put in there personally

    12. If running bbPress, which version? Or did your BuddyPress install come with a copy of bbPress built-in? 2.5.3

    13. Please provide a list of any errors in your server’s log files.

    [Fri Feb 28 14:41:05 2014] [warn] [client xxx] mod_fcgid: stderr: PHP Fatal error: Call to undefined function bp_notifications_toolbar_menu() in /var/www/vhosts/xxx/httpdocs/wp-content/plugins/buddypress/bp-members/bp-members-adminbar.php on line 148, referer: xxx/wp-admin/options-general.php?page=bp-components

    14. Which company provides your hosting? Media Temple

    15. Is your server running Windows, or if Linux; Apache, nginx or something else? Linux and Apache

Viewing 25 results - 126 through 150 (of 329 total)
Skip to toolbar