bp_get_blog_latest_post_content

Return the content of the latest post on the current blog in the loop.

Description

(string) bp_get_blog_latest_post_content(); 

Returns (string)

Content of the blog's latest post.


Usage

  1. if ( !function_exists( 'bp_get_blog_latest_post_content' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'buddypress/bp-blogs/bp-blogs-template.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = bp_get_blog_latest_post_content(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/bp-blogs/bp-blogs-template.php  
  1. function bp_get_blog_latest_post_content() { 
  2. global $blogs_template; 
  3.  
  4. $retval = ''; 
  5.  
  6. if ( ! empty( $blogs_template->blog->latest_post ) && ! empty( $blogs_template->blog->latest_post->post_content ) ) 
  7. $retval = $blogs_template->blog->latest_post->post_content; 
  8.  
  9. /** 
  10. * Filters the content of the latest post on the current blog in the loop. 
  11. * @since 1.7.0 
  12. * @param string $retval Content of the latest post on the current blog in the loop. 
  13. */