aboutsummaryrefslogtreecommitdiff
path: root/mod/lightpics/views/default/object/image/full.php
diff options
context:
space:
mode:
Diffstat (limited to 'mod/lightpics/views/default/object/image/full.php')
-rw-r--r--mod/lightpics/views/default/object/image/full.php62
1 files changed, 62 insertions, 0 deletions
diff --git a/mod/lightpics/views/default/object/image/full.php b/mod/lightpics/views/default/object/image/full.php
new file mode 100644
index 000000000..74436f500
--- /dev/null
+++ b/mod/lightpics/views/default/object/image/full.php
@@ -0,0 +1,62 @@
+<?php
+/**
+ * Full view of an image
+ *
+ * @uses $vars['entity'] TidypicsImage
+ *
+ * @author Cash Costello
+ * @license http://www.gnu.org/licenses/gpl-2.0.html GNU General Public License v2
+ */
+
+$image = $photo = $vars['entity'];
+
+$img = elgg_view_entity_icon($image, 'large', array(
+ 'href' => $image->getIconURL('master'),
+ 'img_class' => 'tidypics-photo',
+ 'link_class' => 'tidypics-lightbox elgg-lightbox-photo',
+));
+
+$owner_link = elgg_view('output/url', array(
+ 'href' => "photos/owner/" . $photo->getOwnerEntity()->username,
+ 'text' => $photo->getOwnerEntity()->name,
+));
+$author_text = elgg_echo('byline', array($owner_link));
+
+$owner_icon = elgg_view_entity_icon($photo->getOwnerEntity(), 'tiny');
+
+$metadata = elgg_view_menu('entity', array(
+ 'entity' => $vars['entity'],
+ 'handler' => 'photos',
+ 'sort_by' => 'priority',
+ 'class' => 'elgg-menu-hz',
+));
+
+$subtitle = "$author_text $date $categories $comments_link";
+
+$params = array(
+ 'entity' => $photo,
+ 'title' => false,
+ 'metadata' => $metadata,
+ 'subtitle' => $subtitle,
+ 'tags' => $tags,
+);
+$list_body = elgg_view('object/elements/summary', $params);
+
+$params = array('class' => 'mbl');
+$summary = elgg_view_image_block($owner_icon, $list_body, $params);
+
+echo $summary;
+
+echo '<div class="tidypics-photo-wrapper center">';
+echo elgg_view('object/image/navigation', $vars);
+echo $img;
+echo '</div>';
+
+if ($photo->description) {
+ echo elgg_view('output/longtext', array(
+ 'value' => $photo->description,
+ 'class' => 'mbl',
+ ));
+}
+
+echo elgg_view_comments($photo);