예제 #1
0
function bp_blog_latest_post() {
	echo bp_get_blog_latest_post();
}
예제 #2
0
/**
 * Output the latest post from the current blog in the loop.
 *
 * @param array $args See {@link bp_get_blog_latest_post()}.
 */
function bp_blog_latest_post($args = array())
{
    echo bp_get_blog_latest_post($args);
}
예제 #3
0
 /**
  * @group bp_get_blog_latest_post
  */
 public function test_bp_get_blog_latest_post_latest_format_false()
 {
     // Fake the global
     global $blogs_template;
     $blogs_template = new stdClass();
     $blogs_template->blog = new stdClass();
     $blogs_template->blog->latest_post = new stdClass();
     $blogs_template->blog->latest_post->guid = 'foo';
     $blogs_template->blog->latest_post->post_title = 'bar';
     $this->assertSame('<a href="foo">bar</a>', bp_get_blog_latest_post(array('latest_format' => false)));
     $blogs_template->blog = null;
 }