Hi Tosin,
May I request you to please stop reminding each 24 hours. That simply pushes your priority low.
@ravisharma will look into it and assist you in next couple of days.Regards
BrajeshThank you.
I sincerely appreciate it.Regards
BrajeshThanks Ravi
add_action( 'bp_activity_entry_meta', function () { global $activities_template; if ( 'new_classified' == $activities_template->activity->type ) { echo "<a href='https://www.site.com/manage-listings/' class='advert-edit-link'>Manage / Edit Ad</a>"; } } );
Hi Tosin,
you may add a condition at the top of the function like thisif ( bp_get_activity_user_id() != get_current_user_id() ) { return; }
It will only shot the button to the creator of the activity.
Regards
BrajeshThanks Brajesh
This worked
add_action( 'bp_activity_entry_meta', function () { global $activities_template; // Check if the current activity's user is the logged in user if ( bp_get_activity_user_id() === get_current_user_id() ) { // Check if the activity type is 'new_classified' if ( 'new_classified' === $activities_template->activity->type ) { echo '<a href="https://www.nigerpress.com/manage-listings/" class="advert-edit-link">Manage / Edit Ad</a>'; } } } );
The topic ‘ [Resolved] Buddyblog activity button’ is closed to new replies.
This topic is: resolved