getGUID(); $list = ''; $num_of_participants = elgg_get_entities_from_relationship(array( 'relationship' => 'subscribes', 'relationship_guid' => $guid, 'inverse_relationship' => true, 'count' => true, )); //var_dump($num_of_participants); if ($num_of_participants) { // display the number of participants if ($num_of_participants == 1) { $participants_string = elgg_echo('tasks:participant', array($num_of_participants)); } else { $participants_string = elgg_echo('tasks:participants', array($num_of_participants)); } $params = array( 'text' => $participants_string, 'title' => elgg_echo('tasks:participants:see'), 'rel' => 'popup', 'href' => "#tasks-participants-$guid" ); $list = elgg_view('output/url', $params); $list .= ""; echo $list; }