Trying to generate an activity id
Been spinning my wheels on this for hours. Trying to generate an $activity_id var using the following:
$activity_id = bp_activity_get_activity_id( array(
‘user_id’ => $post->author_id,
‘type’ => ‘new_blog_post’,
‘component’ => ‘blogs’,
‘item_id’ => 1,
‘secondary_item_id’ => $post->ID
I’m running this in the loop for posts. Essentially I’m trying to recreate a “favorite button” hack I read about here: http://www.dnxpert.com/2010/06/11/mark-blog-post-as-favorite-in-buddypress/ which if you read the comments, does seem to work for people running BP 1.5.5 w/ WP 3.3.
The problem is I simply cannot get the $activity_id to generate. When I try to echo it out I get nothing…if anyone can shed some insight, I would appreciate it immensely.
You must be logged in to reply to this topic.