Go to the source code of this file.
|
| $items = $vars['items'] |
| View a table of items. More...
|
|
| $count = elgg_extract('count', $vars) |
|
| $pagination = elgg_extract('pagination', $vars, true) |
|
| $position = elgg_extract('position', $vars, 'after') |
|
| $no_results = elgg_extract('no_results', $vars, '') |
|
| $cell_views = elgg_extract('cell_views', $vars, ['page/components/table/cell/default']) |
|
| $columns = elgg_extract('columns', $vars) |
|
if(empty($columns)||!is_array($columns)) if(!is_array($items)||count($items)==0) | $headings = '' |
|
| $table_classes = ['elgg-list', 'elgg-table'] |
|
if(isset($vars['list_class'])) | $nav = ($pagination) ? elgg_view('navigation/pagination', $vars) : '' |
|
| $rows = '' |
|
foreach($items as $item) | $body = "$headings<tbody>$rows</tbody>" |
|
| if ($position== 'before'||$position== 'both') |
|
foreach ($columns as $column) $headings = '' |
View a table of items.
$vars['columns'] Array of Elgg If the trimmed rendering doesn't start with "<td" or "<th", then the cell is auto-wrapped with a TD/TH element.
$vars['items'] Array of ElggEntity, ElggAnnotation or ElggRiverItem objects $vars['offset'] Index of the first list item in complete list $vars['limit'] Number of items per page. Only used as input to pagination. $vars['count'] Number of items in the complete list $vars['base_url'] Base URL of list (optional) $vars['url_fragment'] URL fragment to add to links if not present in base_url (optional) $vars['pagination'] Show pagination? (default: true) $vars['position'] Position of the pagination: before, after, or both $vars['full_view'] Show the full view of the items (default: false) $vars['list_class'] Additional CSS class for the
$vars['item_class'] Additional CSS class for the
elements $vars['item_view'] Alternative view to render list items $vars['no_results'] Message to display if no results (string|Closure)
Definition at line 26 of file table.php.