element
 * @uses $vars['item_class']  Additional CSS class for the 
 elements
 */
$items = $vars['items'];
$offset = $vars['offset'];
$limit = $vars['limit'];
$count = $vars['count'];
$base_url = $vars['base_url'];
$pagination = elgg_extract('pagination', $vars, true);
$offset_key = elgg_extract('offset_key', $vars, 'offset');
$position = elgg_extract('position', $vars, 'after');
$list_class = 'elgg-list';
if (isset($vars['list_class'])) {
	$list_class = "$list_class {$vars['list_class']}";
}
$item_class = 'elgg-item';
if (isset($vars['item_class'])) {
	$item_class = "$item_class {$vars['item_class']}";
}
$html = "";
$nav = "";
if ($pagination && $count) {
	$nav .= elgg_view('navigation/pagination', array(
		'baseurl' => $base_url,
		'offset' => $offset,
		'count' => $count,
		'limit' => $limit,
		'offset_key' => $offset_key,
	));
}
if (is_array($items) && count($items) > 0) {
	$html .= "";
	foreach ($items as $item) {
		if (elgg_instanceof($item)) {
			$id = "elgg-{$item->getType()}-{$item->getGUID()}";
		} else {
			$id = "item-{$item->getType()}-{$item->id}";
		}
		$html .= "- ";
		$html .= elgg_view_list_item($item, $vars);
		$html .= '
 ';
	}
	$html .= '
';
}
if ($position == 'before' || $position == 'both') {
	$html = $nav . $html;
}
if ($position == 'after' || $position == 'both') {
	$html .= $nav;
}
echo $html;