• Features & Feedback
  • Created On ,
  • Most Recent By puccino,

Q&A: Buddypress Activity Stream Integration

Please integrate the Q&A plugin with the buddypress activity stream. Having both running separate (like now) from each other kind of defeats the purpose if you run a Q&A website.

    Philip John

    Hiya!

    Although Q&A does work alongside BuddyPress it doesn't integrate in this way, but I agree that would make sense.

    Now that BP 1.5 is out I'm sure the developer will be glad to look into this, so I'll pass your request on.

    Cheers,
    Phil

    LPH

    I just want to +1 this request. Also, there were links to BP.org in another thread and I just wanted to suggest that this code might help the Q&A dev.

    http://pastebin.com/kNqTrRzc

    I don't know the particulars of the Q&A plugin and so adding to the activity stream is a stretch.

    LPH

    OK. I really should be going to work but am intrigued by the BP Skeleton plugin and saw this function for adding to the activity stream.

    function bp_example_record_activity( $args = '' ) {
    global $bp;
    
    if ( !function_exists( 'bp_activity_add' ) )
    return false;
    
    $defaults = array(
    'id' => false,
    'user_id' => $bp->loggedin_user->id,
    'action' => '',
    'content' => '',
    'primary_link' => '',
    'component' => $bp->example->id,
    'type' => false,
    'item_id' => false,
    'secondary_item_id' => false,
    'recorded_time' => gmdate( "Y-m-d H:i:s" ),
    'hide_sitewide' => false
    );
    
    $r = wp_parse_args( $args, $defaults );
    extract( $r );
    
    return bp_activity_add( array( 'id' => $id, 'user_id' => $user_id, 'action' => $action, 'content' => $content, 'primary_link' => $primary_link, 'component' => $component, 'type' => $type, 'item_id' => $item_id, 'secondary_item_id' => $secondary_item_id, 'recorded_time' => $recorded_time, 'hide_sitewide' => $hide_sitewide ) );
    }

    Therefore, we would just need to know how to fill in the last line; the return bp_activity_add array. Right?

    Any suggestions?

    deltakid
    • 63
    • #1713

    Any updates from the dev on this? Will this be in the next update?

    Better subscription handling (maybe integrated in the nice and sleek buddypress subscription management panel under settings) & this activity stream integration and we have an absolute winner here.