Skip to:
Content
Pages
Categories
Search
Top
Bottom

buddypress post thumbnail activity stream

Viewing 4 replies - 1 through 4 (of 4 total)
  • Will not you help me? I found this: http://pastebin.com/jKdQ2kLu
    Received, but the code is old and has a problem. Do not display text. Only featured image (post_thumbnail). Is there a code for the new version? (buddypress 1.6.1)

    Profile photo of ddart
    ddart
    Participant

    @ddart

    I am also interested in this topic.
    It is very important to be able to deduct automatically Featured images (thumbnail) for publication and to show the text to it. Now BP captures first picture in the publication which is unfortunate.
    I hope to be able to add other versions of BP that could be true ..
    Now I hope someone can help!

    Profile photo of zudie
    zudie
    Participant

    @zudie

    Use this code in either your functions.php or bp_custom.php:

    `add_filter( ‘bp_blogs_activity_new_post_content’, ‘my_activity_content’, 2, 10 );
    function my_activity_content($activity_content, $post, $post_permalink){
    $postid=$post->ID;
    $activity_content = get_the_post_thumbnail( $postid );
    $activity_content .= bp_create_excerpt( $post->post_content, 25 );
    return $activity_content;
    }`

    This creates the content block of your activity stream. In the example it adds the thumbnail for the featured image and it creates an excerpt.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘buddypress post thumbnail activity stream’ is closed to new replies.
Skip to toolbar