30 if (!
$object->hasCapability(
'commentable')) {
39 'subtype' =>
'comment',
40 'container_guid' =>
$object->guid,
44 'metadata_name_value_pairs' => [
'level' => 1],
45 'preload_owners' =>
true,
46 'preload_containers' =>
true,
55 'list_class' =>
'elgg-river-comments',
57 'register_rss_link' =>
false,
58 'show_responses' =>
false,
72 $form_vars = [
'id' =>
"comments-add-{$object->guid}-{$item->id}",
'class' =>
'hidden'];
if($comment_count) if(!$object->canComment()) $form_vars
if(!$item instanceof ElggRiverItem) $object
elgg_view_form(string $action, array $form_vars=[], array $body_vars=[])
elgg_echo(string $message_key, array $args=[], string $language= '')
Elgg language module Functions to manage language and translations.
elgg_extract($key, $array, $default=null, bool $strict=true)
Checks for $array[$key] and returns its value if it exists, else returns $default.
if(!empty($item->annotation_id)||!$object instanceof ElggEntity||$object instanceof ElggComment) if(!$object->hasCapability('commentable')) $comment_count
elgg_get_entities(array $options=[])
Fetches/counts entities or performs a calculation on their properties.
if(isset($responses)) $item
if($comment_count) if(!$object->canComment()) $body_vars
Extends QueryBuilder with ORDER BY clauses.
elgg_view_entity_list(array $entities, array $vars=[])
Returns a rendered list of entities with pagination.
elgg_view_url(string $href, string $text=null, array $options=[])
Helper function for outputting urls.
elgg_format_element(string $tag_name, array $attributes=[], string $text= '', array $options=[])
Format an HTML element.