Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: Using bp_blogs_get_latest_posts() Returns An Error


Boone Gorges
Keymaster

@boonebgorges

Not sure why bp_blogs_get_latest_posts() isn’t working for you, but you might try as a more future proof alternative (bp_blogs will be phased out) the activity loop https://codex.buddypress.org/developer-docs/custom-buddypress-loops/the-activity-stream-loop/

So you’d have something like (off the top of my head – probably won’t work without tweaking!)

<?php if (bp_has_activities( 'action=new_blog_post&max=5' ) : while ( bp_activities() ) : bp_the_activity(); ?>
// use the activity loop functions to display information
<?php endwhile; ?>
<?php endif; ?>

BTW – round here I don’t think bumping is too taboo, but the 13 hours between Friday night and Saturday morning are generally not a very busy time on the forums :)

Skip to toolbar