diff options
author | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-08-04 15:03:03 +0000 |
---|---|---|
committer | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-08-04 15:03:03 +0000 |
commit | 43571d4d5381cc3e2a8ba3e05da6cb6982a1d960 (patch) | |
tree | da27c4d097a784fa9cbfa410d57e0709e0c4afb7 /views/default/object | |
parent | 36f52b47f8dc996afcc889b1fd32fd23943103c5 (diff) | |
download | elgg-43571d4d5381cc3e2a8ba3e05da6cb6982a1d960.tar.gz elgg-43571d4d5381cc3e2a8ba3e05da6cb6982a1d960.tar.bz2 |
Fixes #199
git-svn-id: https://code.elgg.org/elgg/trunk@1682 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'views/default/object')
-rw-r--r-- | views/default/object/default.php | 48 |
1 files changed, 47 insertions, 1 deletions
diff --git a/views/default/object/default.php b/views/default/object/default.php index 93dd2ca94..c38b243ec 100644 --- a/views/default/object/default.php +++ b/views/default/object/default.php @@ -10,5 +10,51 @@ * @link http://elgg.org/ */ - echo elgg_view('export/entity', $vars); + if ($vars['full']) { + echo elgg_view('export/entity', $vars); + } else { + + $icon = elgg_view( + 'graphics/icon', array( + 'entity' => $vars['entity'], + 'size' => 'small', + ) + ); + + + $title = $vars['entity']->title; + if (!$title) $title = $vars['entity']->name; + if (!$title) $title = get_class($vars['entity']); + + $controls = ""; + if ($vars['entity']->canEdit()) + { + $controls .= " (<a href=\"{$vars['url']}actions/entities/delete?guid={$vars['entity']->guid}\">" . elgg_echo('delete') . "</a>)"; + } + + $info = "<div><p><b><a href=\"" . $vars['entity']->getUrl() . "\">" . $title . "</a></b> $controls </p></div>"; + + if (get_input('search_viewtype') == "gallery") { + + $icon = ""; + + } + + $owner = $vars['entity']->getOwnerEntity(); + $ownertxt = elgg_echo('unknown'); + if ($owner) + "<a href=\"" . $owner->getURL() . "\">" . $owner->name ."</a>"; + + $info .= "<div>".sprintf(elgg_echo("entity:default:strapline"), + friendly_time($vars['entity']->time_created), + $ownertxt + ); + + $info .= "</div>"; + + $info = "<span title=\"" . elgg_echo('entity:default:missingsupport:popup') . "\">$info</span>"; + $icon = "<span title=\"" . elgg_echo('entity:default:missingsupport:popup') . "\">$icon</span>"; + + echo elgg_view_listing($icon, $info); + } ?>
\ No newline at end of file |