How can I display the total number of favorites for any particular buddypress activity stream post? [closed]

Unfortunately, it’s not really feasible, based on the current implementation of activity favorites in BuddyPress. BP stores this data in a piece of usermeta called ‘bp_favorite_activities’, which is an array of activity ids. That makes it easy and fast to pull up a list of a given member’s favorite activity items; but it makes it … Read more

How to create a customized logout URL in BuddyPress

That’s the same as the regular WordPress logout URL. So you can use the same filter: ‘logout_url’. Sample code, not tested: add_filter( ‘logout_url’, ‘wpse_56866_logout_url’ ); function wpse_56866_logout_url() { // set your URL here return ‘http://example.com’; }

Buddypress shortcode for tabs [closed]

Use the following code, function custom_add_activity_tab() { ?> <li id=”custom-tab”> <a href=”https://wordpress.stackexchange.com/questions/60691/<?php echo site_url( BP_ACTIVITY_SLUG .”https://wordpress.stackexchange.com/” ) ?>” title=”<?php _e( ‘Tab.’, ‘buddypress’ ) ?>”> <?php printf( __( ‘tab’ , ‘buddypress’ ) ); ?> </a> </li> <?php } add_action( ‘bp_activity_type_tabs’, ‘custom_add_activity_tab’ ); Check it, Will work better

Add excerpt and post thumbnail to Buddypress blog directory page [closed]

I don’t have a complete answer for you. But I can point out that you should use the filter hook provided in the function bp_blog_latest_post() So something like: add_filter(‘bp_get_blog_latest_post’, ‘your_function’, 1); function your_function( ) { global $blogs_template; $str = // build your string to include excerpt and thumbnail return $str; } I don’t recall if … Read more

How to Display BuddyPress Profile Field Data In Multisite Blogs [closed]

After playing around with it a bit more, here’s what finally worked for me: global $bp; $thisblog = $current_blog->blog_id; $user_from_email = get_user_by(’email’, get_blog_option($thisblog, ‘admin_email’)); $user_id = $user_from_email->ID; $myfield = xprofile_get_field_data( ‘Counties Served’, $user_id, $multi_format=”comma” ); $data = xprofile_format_profile_field(‘checkbox’, $myfield); echo $data;