From 0d35e43b9125063af76ef34caabac9dfc95eae01 Mon Sep 17 00:00:00 2001 From: cash Date: Sat, 12 Mar 2011 14:37:16 +0000 Subject: Refs #3085 improved documentation of elgg_view_entity_list() which already supported $vars array git-svn-id: http://code.elgg.org/elgg/trunk@8657 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/lib/views.php | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'engine') diff --git a/engine/lib/views.php b/engine/lib/views.php index 25d5ea58a..199f79dae 100644 --- a/engine/lib/views.php +++ b/engine/lib/views.php @@ -920,10 +920,10 @@ function elgg_view_annotation(ElggAnnotation $annotation, $full = true, $bypass * 'gallery' Display as gallery? * 'list_type_toggle' Display the list type toggle? * - * @return string The list of entities + * @return string The rendered list of entities * @access private */ -function elgg_view_entity_list($entities, $count, $offset = 0, $limit = 10, $full_view = true, +function elgg_view_entity_list($entities, $vars, $offset = 0, $limit = 10, $full_view = true, $list_type_toggle = true, $pagination = true) { if (!is_int($offset)) { @@ -942,14 +942,15 @@ $list_type_toggle = true, $pagination = true) { 'offset' => $offset, ); - $vars = array_merge($defaults, $count); + $vars = array_merge($defaults, $vars); } else { - // old function - because this is an internal function we can remove - // this in Elgg 1.9 without following the normal deprecation procedures + // old function parameters + elgg_deprecated_notice("Please update your use of elgg_view_entity_list()", 1.8); + $vars = array( 'items' => $entities, - 'count' => (int) $count, + 'count' => (int) $vars, // the old count parameter 'offset' => $offset, 'limit' => (int) $limit, 'full_view' => $full_view, -- cgit v1.2.3