WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Where would I begin if I wanted to rename a string in the buddypress activity stream?

Instead of it saying "so and so wrote a new post", I would like it to say "so and so wrote a new article" (or whatever word I choose)


share|improve this question

closed as off-topic by ialocin, kaiser Aug 4 '14 at 14:32

This question appears to be off-topic. The users who voted to close gave this specific reason:

If this question can be reworded to fit the rules in the help center, please edit the question.

up vote 1 down vote accepted

Got it

add_filter('bp_blogs_activity_new_post_action', 'record_cpt_activity_action', 1, 3);
function record_cpt_activity_action( $activity_action,  $post, $post_permalink ) { 
    global $bp;
    if( $post->post_type == 'post' ) {
        if ( is_multisite() )
            $activity_action  = sprintf( __( '%1$s wrote a new article, %2$s, on the site %3$s', 'buddypress' ), bp_core_get_userlink( (int) $post->post_author ), '<a href="' . $post_permalink . '">' . $post->post_title . '</a>', '<a href="' . get_blog_option( $blog_id, 'home' ) . '">' . get_blog_option( $blog_id, 'blogname' ) . '</a>' );

               $activity_action  = sprintf( __( '%1$s wrote a new article, %2$s', 'buddypress' ), bp_core_get_userlink( (int) $post->post_author ), '<a href="' . $post_permalink . '">' . $post->post_title . '</a>' );


    return $activity_action;
share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.