Elgg  Version 2.3
Variables
comment.php File Reference

Go to the source code of this file.

Variables

 $full_view = elgg_extract('full_view', $vars, true)
 Elgg comment view. More...
 
 $comment = $vars['entity']
 
 $entity = get_entity($comment->container_guid)
 
 $commenter = get_user($comment->owner_guid)
 
if(!$entity||!$commenter) $friendlytime = elgg_view_friendly_time($comment->time_created)
 
 $commenter_icon = elgg_view_entity_icon($commenter, 'tiny')
 
 $commenter_link = "<a href=\"{$commenter->getURL()}\">$commenter->name</a>"
 
 $entity_title = $entity->title ? $entity->title : elgg_echo('untitled')
 
 $entity_link = "<a href=\"{$entity->getURL()}\">$entity_title</a>"
 
if($full_view) else
 
 $posted = elgg_echo('generic_comment:on', array($commenter_link, $entity_link))
 
 $body
 

Variable Documentation

$body
Initial value:
= <<<HTML
<span class="elgg-subtext">
</span>
HTML
ui datepicker td span
Definition: admin.css.php:680
$posted
Definition: comment.php:83
if(!$entity||!$commenter) $friendlytime
Definition: comment.php:20
if($string_length<=$num_chars) $excerpt
Definition: excerpt.php:24

Definition at line 85 of file comment.php.

$comment = $vars['entity']

Definition at line 11 of file comment.php.

$commenter = get_user($comment->owner_guid)

Definition at line 15 of file comment.php.

$commenter_icon = elgg_view_entity_icon($commenter, 'tiny')

Definition at line 22 of file comment.php.

$commenter_link = "<a href=\"{$commenter->getURL()}\">$commenter->name</a>"

Definition at line 23 of file comment.php.

Definition at line 14 of file comment.php.

$entity_link = "<a href=\"{$entity->getURL()}\">$entity_title</a>"

Definition at line 26 of file comment.php.

$entity_title = $entity->title ? $entity->title : elgg_echo('untitled')

Definition at line 25 of file comment.php.

if (!$entity||!$commenter) $friendlytime = elgg_view_friendly_time($comment->time_created)

Definition at line 20 of file comment.php.

$full_view = elgg_extract('full_view', $vars, true)

Elgg comment view.

$vars['entity'] ElggComment $vars['full_view'] Display full view or brief view

Examples:
/root/Elgg/engine/lib/views.php.

Definition at line 9 of file comment.php.

$posted = elgg_echo('generic_comment:on', array($commenter_link, $entity_link))

Definition at line 83 of file comment.php.

if ($full_view) else
Initial value:
{
$excerpt = elgg_get_excerpt($comment->description, 80)
elgg_get_excerpt($text, $num_chars=250)
Returns an excerpt.
Definition: output.php:62
$comment
Definition: comment.php:11
if($string_length<=$num_chars) $excerpt
Definition: excerpt.php:24

Definition at line 79 of file comment.php.