owner_guid); $container = get_entity($blog->container_guid); $linked_title = "getURL()}\" title=\"" . htmlentities($blog->title) . "\">{$blog->title}"; $categories = elgg_view('categories/view', $vars); $excerpt = $blog->excerpt; $body = autop($blog->description); $owner_icon = elgg_view("profile/icon",array('entity' => $owner, 'size' => 'tiny')); $tags = elgg_view('output/tags', array('tags' => $blog->tags)); $date = friendly_time($blog->publish_date); // The "on" status changes for comments, so best to check for !Off if ($blog->comments_on != 'Off') { $comments_count = elgg_count_comments($blog); $comments_link = "getURL()}#annotations\">" . sprintf(elgg_echo("comments"), $comments_count) . ''; } else { $comments_link = ''; } // links to delete or edit. $edit = ''; if ($blog->canEdit()) { $edit_url = "{$vars['url']}pg/blog/{$owner->username}/edit/{$blog->getGUID()}/"; $edit_link = "" . elgg_echo('edit') . ''; $delete_url = "{$vars['url']}action/blog/delete?guid={$blog->getGUID()}"; $delete_link = "" . elgg_view('output/confirmlink', array( 'href' => $delete_url, 'text' => elgg_echo('delete'), 'confirm' => elgg_echo('deleteconfirm') )) . ""; $status = ''; if ($blog->status != 'published') { $status_text = elgg_echo("blog:status:{$blog->status}"); $status = "$status_text"; } $edit = "$status $edit_link $delete_link"; } // include a view for plugins to extend $edit = elgg_view("blogs/options", array("object_type" => 'blog', 'entity' => $blog)) . elgg_view_likes($blog) . // include likes $edit; if ($full) { echo <<<___END

{$blog->title}

$owner_icon

$date $categories $comments_link

$tags

$body
___END; } else { echo <<<___END
$owner_icon

$linked_title

$date $categories $comments_link

$tags

$excerpt

___END; }