Remove post content from buddypress activity [closed]

You should state which versions of WP and BP you’re using. This should change the content part of what is recorded. You can put it in your theme’s functions.php add_filter( ‘bp_blogs_activity_new_post_content’, ‘record_post_activity_content’, 1, 3 ); function record_post_activity_content($activity_content, $post, $post_permalink ){ if( $post->post_type == ‘post’ ) { $activity_content=”your custom field”; } return $activity_content; }

BuddyPress – Get a List of Defined xProfile fields [closed]

You can pass the user id in Bp Profile loop to get hold of alll the fields and their values. <?php if ( bp_has_profile(array(‘user_id’ => 1)) ) : while ( bp_profile_groups() ) : bp_the_profile_group(); ?> <ul id=”profile-groups”> <?php if ( bp_profile_group_has_fields() ) : ?> <li> <?php bp_the_profile_group_name() ?> <ul id=”profile-group-fields”> <?php while ( bp_profile_fields() ) … Read more

Buddypress – adding custom post to members

There are more problems: 1) Add the activity on adding meeting You could use the save_post hook to add activity, but I’d rather add custom notification, as the activity item can be easily missed. The how to is described in this great tutorial https://webdevstudios.com/2015/10/06/buddypress-adding-custom-notifications/ 2) Let the users view the post You should save post_meta … Read more

Add an extra field to BuddyPress activity form

First of all, there is only 1 $accepted_args, not 3, so the add_action is: add_action(‘bp_activity_after_save’, ‘where_activity_from’, 10, 1); Second, the value in your tags input is never parsed by BP_Activity_Activity->save() so how could it be part of the array available thru the hook? Try using the $_POST array, like this: add_action(‘bp_activity_after_save’, ‘where_activity_from’, 10, 1); function … Read more

How to edit buddypress templates? [closed]

BuddyPress themes are WordPress themes, plus extra templates. I encourage you to use the BuddyPress Template Pack plugin to enable these extra templates: http://wordpress.org/extend/plugins/bp-template-pack/ Here’s a bit of background on how to build a BP-compatible child theme: http://codex.buddypress.org/theme-development/bp-template-pack-walkthrough-level-easy-2/ This link actually uses TwentyTen as an example: http://codex.buddypress.org/theme-development/theme-dev-bp-template-pack-walkthrough-twenty-ten-bp-1-5/

Show activities of defined BuddyPress groups [closed]

After getting all the groups_ids i get all activities_ids by doing: <?php global $bp,$wpdb; $groups_ids = implode(‘, ‘, $groups_ids); $sql = “SELECT id FROM {$bp->activity->table_name} WHERE component=”groups” AND item_id IN ({$groups_ids})”; $activity_ids = $wpdb->get_results( $sql); $a_id = array(); foreach ($activity_ids as $activity_id ) { $a_id[] = $activity_id->id; } ?> Then i get only one activity … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)