aboutsummaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
Diffstat (limited to 'views')
-rw-r--r--views/default/entities/entity_list.php63
-rw-r--r--views/default/entities/entity_listing.php19
-rw-r--r--views/default/entities/gallery.php42
-rw-r--r--views/default/entities/gallery_listing.php21
-rw-r--r--views/default/entities/list.php63
-rw-r--r--views/default/entities/list_item.php19
-rw-r--r--views/default/graphics/icon.php44
-rw-r--r--views/default/object/default.php6
8 files changed, 1 insertions, 276 deletions
diff --git a/views/default/entities/entity_list.php b/views/default/entities/entity_list.php
deleted file mode 100644
index fd6ea27bb..000000000
--- a/views/default/entities/entity_list.php
+++ /dev/null
@@ -1,63 +0,0 @@
-<?php
-/**
- * View a list of entities
- *
- * @package Elgg
- *
- */
-
-$context = $vars['context'];
-$offset = $vars['offset'];
-$entities = $vars['entities'];
-$limit = $vars['limit'];
-$count = $vars['count'];
-$baseurl = $vars['baseurl'];
-$context = $vars['context'];
-$listtype = $vars['listtype'];
-$pagination = $vars['pagination'];
-$fullview = $vars['fullview'];
-
-$html = "";
-$nav = "";
-
-if (isset($vars['listtypetoggle'])) {
- $listtypetoggle = $vars['listtypetoggle'];
-} else {
- $listtypetoggle = true;
-}
-
-if ($context == "search" && $count > 0 && $listtypetoggle) {
- $nav .= elgg_view('navigation/listtype', array(
- 'baseurl' => $baseurl,
- 'offset' => $offset,
- 'count' => $count,
- 'listtype' => $listtype,
- ));
-}
-
-if ($pagination) {
- $nav .= elgg_view('navigation/pagination',array(
- 'baseurl' => $baseurl,
- 'offset' => $offset,
- 'count' => $count,
- 'limit' => $limit,
- ));
-}
-
-if ($listtype == 'list') {
- if (is_array($entities) && sizeof($entities) > 0) {
- foreach($entities as $entity) {
- $html .= elgg_view_entity($entity, $fullview);
- }
- }
-} else {
- if (is_array($entities) && sizeof($entities) > 0) {
- $html .= elgg_view('entities/gallery', array('entities' => $entities));
- }
-}
-
-if ($count) {
- $html .= $nav;
-}
-
-echo $html; \ No newline at end of file
diff --git a/views/default/entities/entity_listing.php b/views/default/entities/entity_listing.php
deleted file mode 100644
index 4b6636db7..000000000
--- a/views/default/entities/entity_listing.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-/**
- * Generic display for a single entity in list view.
- *
- * @package Elgg
- * @subpackage Core
- *
- * @uses string $vars['icon'] Full icon HTML to display.
- * @uses string $vars['info'] Info about the entity.
- */
-?>
-<div class="listing entity-listing">
- <div class="icon">
- <?php echo $vars['icon']; ?>
- </div>
- <div class="info">
- <?php echo $vars['info']; ?>
- </div>
-</div>
diff --git a/views/default/entities/gallery.php b/views/default/entities/gallery.php
deleted file mode 100644
index bfdd4d4d8..000000000
--- a/views/default/entities/gallery.php
+++ /dev/null
@@ -1,42 +0,0 @@
-<?php
-/**
- * Elgg gallery view
- *
- * @package Elgg
- * @subpackage Core
- */
-
-$entities = $vars['entities'];
-if (is_array($entities) && sizeof($entities) > 0) {
-
-?>
-
-<table class="entity_gallery">
-
-<?php
-
- $col = 0;
- foreach($entities as $entity) {
- if ($col == 0) {
-
- echo "<tr>";
-
- }
- echo "<td class='entity_gallery_item'>";
- echo elgg_view_entity($entity);
- echo "</td>";
- $col++;
- if ($col > 3) {
- echo "</tr>";
- $col = 0;
- }
- }
- if ($col > 0) echo "</tr>";
-
-?>
-
-</table>
-
-<?php
-
-} \ No newline at end of file
diff --git a/views/default/entities/gallery_listing.php b/views/default/entities/gallery_listing.php
deleted file mode 100644
index 58fa5e26b..000000000
--- a/views/default/entities/gallery_listing.php
+++ /dev/null
@@ -1,21 +0,0 @@
-<?php
-/**
- * Generic display for a single entity in gallery view.
- *
- * @package Elgg
- * @subpackage Core
- *
- * @uses string $vars['icon'] Full icon HTML to display.
- * @uses string $vars['info'] Info about the entity.
- */
-
-?>
-
-<div class="gallery_listing clearfix">
- <div class="gallery_listing_icon">
- <?php echo $vars['icon']; ?>
- </div>
- <div class="gallery_listing_info">
- <?php echo $vars['info']; ?>
- </div>
-</div>
diff --git a/views/default/entities/list.php b/views/default/entities/list.php
deleted file mode 100644
index 2ddd96ee9..000000000
--- a/views/default/entities/list.php
+++ /dev/null
@@ -1,63 +0,0 @@
-<?php
-/**
- * View a list of entities
- *
- * @package Elgg
- *
- */
-
-$context = $vars['context'];
-$offset = $vars['offset'];
-$entities = $vars['entities'];
-$limit = $vars['limit'];
-$count = $vars['count'];
-$base_url = $vars['baseurl'];
-$context = $vars['context'];
-$list_type = $vars['listtype'];
-$pagination = $vars['pagination'];
-$full_view = $vars['fullview'];
-
-$html = "";
-$nav = "";
-
-$list_type_toggle = elgg_get_array_value('listtypetoggle', $vars, true);
-
-if ($context == "search" && $count > 0 && $list_type_toggle) {
- $nav .= elgg_view('navigation/listtype', array(
- 'baseurl' => $base_url,
- 'offset' => $offset,
- 'count' => $count,
- 'listtype' => $list_type,
- ));
-}
-
-if ($pagination) {
- $nav .= elgg_view('navigation/pagination', array(
- 'baseurl' => $base_url,
- 'offset' => $offset,
- 'count' => $count,
- 'limit' => $limit,
- ));
-}
-
-if ($list_type == 'list') {
- if (is_array($entities) && sizeof($entities) > 0) {
- $html .= '<ul class="elgg-entity-list elgg-list">';
- foreach ($entities as $entity) {
- $html .= '<li>';
- $html .= elgg_view_entity($entity, $full_view);
- $html .= '</li>';
- }
- $html .= '</ul>';
- }
-} else {
- if (is_array($entities) && sizeof($entities) > 0) {
- $html .= elgg_view('entities/gallery', array('entities' => $entities));
- }
-}
-
-if ($count) {
- $html .= $nav;
-}
-
-echo $html;
diff --git a/views/default/entities/list_item.php b/views/default/entities/list_item.php
deleted file mode 100644
index 4b6636db7..000000000
--- a/views/default/entities/list_item.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-/**
- * Generic display for a single entity in list view.
- *
- * @package Elgg
- * @subpackage Core
- *
- * @uses string $vars['icon'] Full icon HTML to display.
- * @uses string $vars['info'] Info about the entity.
- */
-?>
-<div class="listing entity-listing">
- <div class="icon">
- <?php echo $vars['icon']; ?>
- </div>
- <div class="info">
- <?php echo $vars['info']; ?>
- </div>
-</div>
diff --git a/views/default/graphics/icon.php b/views/default/graphics/icon.php
deleted file mode 100644
index 06e866d33..000000000
--- a/views/default/graphics/icon.php
+++ /dev/null
@@ -1,44 +0,0 @@
-<?php
-/**
- * Generic icon view.
- *
- * @package Elgg
- * @subpackage Core
- *
- * @uses $vars['entity'] The entity the icon represents - uses getIcon() method
- * @uses $vars['js'] Any JavaScript to add to img tag
- * @uses $vars['size'] topbar, tiny, small, medium (default), large, master
- * @uses $vars['link'] Optional link for the image
- * @uses $vars['align'] Align attribute of the img tag
- */
-
-$entity = $vars['entity'];
-
-$sizes = array('small','medium','large','tiny','master','topbar');
-// Get size
-if (!in_array($vars['size'], $sizes)) {
- $vars['size'] = "medium";
-}
-
-// Get any align and js
-if (!empty($vars['align'])) {
- $align = " align=\"{$vars['align']}\" ";
-} else {
- $align = "";
-}
-
-
-?>
-<div class="icon">
-<?php
-if ($vars['link']) {
- ?><a href="<?php echo $vars['link'] ?>"><?php
-}
-?>
-<img src="<?php echo $entity->getIcon($vars['size']); ?>" <?php echo $align; ?> <?php echo $vars['js']; ?> />
-<?php
-if ($vars['link']) {
- ?></a><?php
-}
-?>
-</div> \ No newline at end of file
diff --git a/views/default/object/default.php b/views/default/object/default.php
index be2be475e..bcb1b04fd 100644
--- a/views/default/object/default.php
+++ b/views/default/object/default.php
@@ -8,11 +8,7 @@
* @subpackage Core
*/
-$icon = elgg_view('graphics/icon', array(
- 'entity' => $vars['entity'],
- 'size' => 'small',
-));
-
+$icon = elgg_view_entity_icon($vars['entity'], 'small');
$title = $vars['entity']->title;
if (!$title) {