From 02d6d67dcf6a90cfd515850cf1d93eb8795c55bd Mon Sep 17 00:00:00 2001 From: ben Date: Thu, 3 Apr 2008 10:05:41 +0000 Subject: Update for elgg_view_entity git-svn-id: https://code.elgg.org/elgg/trunk@386 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/lib/elgglib.php | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'engine/lib/elgglib.php') diff --git a/engine/lib/elgglib.php b/engine/lib/elgglib.php index fab984fbe..ab470d2fe 100644 --- a/engine/lib/elgglib.php +++ b/engine/lib/elgglib.php @@ -162,11 +162,12 @@ * * @param ElggEntity $entity The entity to display * @param string $viewtype Optionally, the type of view that we're using (most commonly 'default') + * @param boolean $full Determines whether or not to display the full version of an object, or a smaller version for use in aggregators etc * @param boolean $debug If set to true, elgg_view will bypass any specified alternative template handler; by default, it will hand off to this if requested (see set_template_handler) * @param boolean $debug If set to true, the viewer will complain if it can't find a view * @return string HTML (etc) to display */ - function elgg_view_entity(ElggEntity $entity, $viewtype = "", $bypass = true, $debug = false) { + function elgg_view_entity(ElggEntity $entity, $viewtype = "", $full = false, $bypass = true, $debug = false) { $view = $entity->view; if (is_string($view)) { @@ -194,7 +195,13 @@ if (!isset($entity_class)) return false; $subtype = $entity->getSubtype(); - return elgg_view("{$entity_type}/{$subtype}",array('entity' => $entity), $viewtype, $bypass, $debug); + $owner = get_entity($entity->getOwner()); + + return elgg_view("{$entity_type}/{$subtype}",array( + 'entity' => $entity, + 'owner' => $owner, + 'full' => $full + ), $viewtype, $bypass, $debug); } -- cgit v1.2.3