working nicely, just need to filter out ‘joined the group.. and created group.. and remove ‘view’ and delete’.
Once im done using it for what i need ill turn it into a widget for the community
function bp_limit_group_activity_content() {
$group_activity_length = 100; //character limit
$group_excerpt = substr(bp_get_activity_content_body(), 0, $group_activity_length); //truncate excerpt according to lenngth
if(strlen($group_excerpt) < strlen(bp_get_activity_content_body())) {
$group_excerpt = $group_excerpt.'..' ;
}
echo "<p>".$group_excerpt."</p>"; //finally display excerpt
}
and then calling it by
<?php if ( bp_has_activities('scope=groups') ) : ?>
<div id="news-container">
<ul id="activity-stream" class="activity-list item-list">
<?php while ( bp_activities() ) : bp_the_activity(); ?>
<li class="<?php bp_activity_css_class() ?>" id="activity-<?php bp_activity_id() ?>">
<div class="activity-content">
<div class="activity-header">
<?php bp_activity_action() ?>
</div>
<a href="<?php bp_activity_thread_permalink() ?>"><?php bp_limit_group_activity_content() ?></a>
<?php do_action( 'bp_activity_entry_content' ) ?>
</div>
</li>
<?php endwhile; ?>
</ul>
</div>
<?php else : ?>
<div id="message" class="info">
<p><?php _e( 'Join groups to get feed.', 'buddypress' ) ?></p>
</div>
<?php endif; ?>