aboutsummaryrefslogtreecommitdiff
path: root/mod/blog/views/default/river
diff options
context:
space:
mode:
Diffstat (limited to 'mod/blog/views/default/river')
-rw-r--r--mod/blog/views/default/river/object/blog/create.php18
1 files changed, 10 insertions, 8 deletions
diff --git a/mod/blog/views/default/river/object/blog/create.php b/mod/blog/views/default/river/object/blog/create.php
index fef666814..d59d601f5 100644
--- a/mod/blog/views/default/river/object/blog/create.php
+++ b/mod/blog/views/default/river/object/blog/create.php
@@ -1,20 +1,22 @@
<?php
/**
* Blog river view.
- *
- * @package Blog
- * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
- * @author Curverider Ltd
- * @copyright Curverider Ltd 2008-2010
- * @link http://elgg.org/
*/
$performed_by = get_entity($vars['item']->subject_guid);
$object = get_entity($vars['item']->object_guid);
$url = $object->getURL();
+$contents = strip_tags($object->description); //strip tags from the contents to stop large images etc blowing out the river view
$url = "<a href=\"{$performed_by->getURL()}\">{$performed_by->name}</a>";
$title = sprintf(elgg_echo('blog:river:create'), $url);
-$string .= "<a href=\"" . $object->getURL() . "\">" . $object->title . "</a> <span class='entity_subtext'>" . friendly_time($object->publish_time) . "</span>";
-
+$string .= $title . " <a href=\"" . $object->getURL() . "\">" . $object->title . "</a> <span class='entity_subtext'>" . friendly_time($object->publish_time) . "</span>";
+$string .= "<div class=\"river_content_display\">";
+ $string .= "<div class='river_object_blog_create'></div>";
+ if(strlen($contents) > 200) {
+ $string .= substr($contents, 0, strpos($contents, ' ', 200)) . "...";
+ }else{
+ $string .= $contents;
+ }
+ $string .= "</div>";
echo $string; \ No newline at end of file