aboutsummaryrefslogtreecommitdiff
path: root/mod/cool_theme/views/default/river/elements/attachment.php
diff options
context:
space:
mode:
Diffstat (limited to 'mod/cool_theme/views/default/river/elements/attachment.php')
-rw-r--r--mod/cool_theme/views/default/river/elements/attachment.php25
1 files changed, 25 insertions, 0 deletions
diff --git a/mod/cool_theme/views/default/river/elements/attachment.php b/mod/cool_theme/views/default/river/elements/attachment.php
new file mode 100644
index 000000000..d5c0aab99
--- /dev/null
+++ b/mod/cool_theme/views/default/river/elements/attachment.php
@@ -0,0 +1,25 @@
+<?php
+
+$title = '';
+$subtitle = false;
+$image = false;
+$description = false;
+
+extract($vars, EXTR_IF_EXISTS);
+
+$body = "<h4 class=\"elgg-attachment-title\">$title</h4>";
+
+if ($subtitle) {
+ $body .= "<div class=\"elgg-attachment-subtitle\">$subtitle</div>";
+}
+
+if ($description) {
+ $body .= "<div class=\"elgg-attachment-description\">$description</div>";
+}
+
+
+if ($image) {
+ echo elgg_view_image_block($image, $body);
+} else {
+ echo $body;
+} \ No newline at end of file