";
echo "
" . elgg_echo('latestcomments') . "
";
foreach($vars['comments'] as $comment){
//grab the entity the comment is on
$entity = get_entity($comment->entity_guid);
//comment owner
$comment_owner = get_user($comment->owner_guid);
$friendlytime = friendly_time($comment->time_created); // get timestamp for comment
//set the title
if($entity->title)
$objecttitle = $entity->title;
else
$objecttitle = elgg_echo('file:untitled');
//if the entity has been deleted, don't link to it
if($entity){
$url = $entity->getURL(); // get url to file for comment link
$url_display = "{$objecttitle}";
//$owner = $entity->getOwnerEntity(); // get file owner
}else{
$url_display = $objecttitle;
}
echo "";
}
echo "";
}