aboutsummaryrefslogtreecommitdiff
path: root/mod/file/views/default/object/file.php
diff options
context:
space:
mode:
authorSem <sembrestels@riseup.net>2011-11-18 07:32:27 +0100
committerSem <sembrestels@riseup.net>2011-11-18 07:32:27 +0100
commite53d410129701ea1c9d19529afa493f11b5f5b70 (patch)
treed9963b24bf8932654b4a47e36602c75975e50dba /mod/file/views/default/object/file.php
parent377da25d2965c64941f83baae119fc970ec60982 (diff)
parent08a962c98e2923724f8013d6eaae89101243752a (diff)
downloadelgg-e53d410129701ea1c9d19529afa493f11b5f5b70.tar.gz
elgg-e53d410129701ea1c9d19529afa493f11b5f5b70.tar.bz2
Merge github.com:Elgg/Elgg
Conflicts: engine/lib/input.php
Diffstat (limited to 'mod/file/views/default/object/file.php')
-rw-r--r--mod/file/views/default/object/file.php28
1 files changed, 13 insertions, 15 deletions
diff --git a/mod/file/views/default/object/file.php b/mod/file/views/default/object/file.php
index 95e190d35..1db9863c9 100644
--- a/mod/file/views/default/object/file.php
+++ b/mod/file/views/default/object/file.php
@@ -19,11 +19,10 @@ $excerpt = elgg_get_excerpt($file->description);
$mime = $file->mimetype;
$base_type = substr($mime, 0, strpos($mime,'/'));
-$body = elgg_view('output/longtext', array('value' => $file->description));
-
$owner_link = elgg_view('output/url', array(
'href' => "file/owner/$owner->username",
'text' => $owner->name,
+ 'is_trusted' => true,
));
$author_text = elgg_echo('byline', array($owner_link));
@@ -39,6 +38,7 @@ if ($comments_count != 0) {
$comments_link = elgg_view('output/url', array(
'href' => $file->getURL() . '#file-comments',
'text' => $text,
+ 'is_trusted' => true,
));
} else {
$comments_link = '';
@@ -51,7 +51,7 @@ $metadata = elgg_view_menu('entity', array(
'class' => 'elgg-menu-hz',
));
-$subtitle = "$author_text $date $categories $comments_link";
+$subtitle = "$author_text $date $comments_link $categories";
// do not show the metadata and controls in widget view
if (elgg_in_context('widgets')) {
@@ -67,27 +67,25 @@ if ($full && !elgg_in_context('gallery')) {
$extra = elgg_view("file/specialcontent/$base_type/default", $vars);
}
- $header = elgg_view_title($file->title);
-
$params = array(
'entity' => $file,
- 'title' => false,
'metadata' => $metadata,
'subtitle' => $subtitle,
'tags' => $tags,
);
$params = $params + $vars;
- $list_body = elgg_view('object/elements/summary', $params);
+ $summary = elgg_view('object/elements/summary', $params);
- $file_info = elgg_view_image_block($file_icon, $list_body);
+ $text = elgg_view('output/longtext', array('value' => $file->description));
+ $body = "$text $extra";
- echo <<<HTML
-$file_info
-<div class="file elgg-content">
- $body
- $extra
-</div>
-HTML;
+ echo elgg_view('object/elements/full', array(
+ 'entity' => $file,
+ 'title' => false,
+ 'icon' => $file_icon,
+ 'summary' => $summary,
+ 'body' => $body,
+ ));
} elseif (elgg_in_context('gallery')) {
echo '<div class="file-gallery-item">';