'blog'));
// fetch & display latest comments on all blog posts
echo elgg_view_latest_comments(0, 'object', 'blog');
// only show archives for users or groups.
// This is a limitation of the URL schema.
if ($page_owner && $vars['page'] != 'friends') {
$dates = blog_get_blog_months($user);
if ($dates) {
$title = elgg_echo('blog:archives');
$content = '
';
foreach($dates as $date) {
$date = $date->yearmonth;
$timestamplow = mktime(0, 0, 0, substr($date,4,2) , 1, substr($date, 0, 4));
$timestamphigh = mktime(0, 0, 0, ((int) substr($date, 4, 2)) + 1, 1, substr($date, 0, 4));
$link = elgg_get_site_url() . 'pg/blog/archive/' . $page_owner->username . '/' . $timestamplow . '/' . $timestamphigh;
$month = elgg_echo('date:month:' . substr($date, 4, 2), array(substr($date, 0, 4)));
$content .= "- $month
";
}
$content .= '
';
echo elgg_view('layout/objects/module', array('title' => $title, 'body' => $content));
}
// friends page lists all tags; mine lists owner's
$owner_guid = ($vars['page'] == 'friends') ? '' : $page_owner->getGUID();
$options = array(
'type' => 'object',
'subtype' => 'blog',
'owner_guid' => $owner_guid,
'threshold' => 0,
'limit' => 50,
'tag_name' => 'tags',
);
echo elgg_view_tagcloud($options);
} else {
$options = array(
'type' => 'object',
'subtype' => 'blog',
'threshold' => 0,
'limit' => 50,
'tag_name' => 'tags',
);
echo elgg_view_tagcloud($options);
}