Facebook like river dashboard/模仿Facebook的river dashboard v0.53

Release Notes

New version released in plugin pack from snow.

This plugin is nearly stable,but I still suggest to test it in a local site before use in a public site.

改进到现在已经比较稳定了,不过还是建议先在测试站点上试一下没问题在用在运营中的网站上

What's this?

A modify to the riverdashboard.

  • Comment on a river item right on the riverdashboard.
  • List comments of a river item
  • show some object right in river,such as tidypic images.

Installation

Extract the two folder,riverdashboard and pack_of_roaming_cat into your elgg's mod folder.

What's new in 0.53

  • Bug fix.this is the nearly-stable version
  • show blog full content in river
  • show a loading icon when loading river image
  • fixes for IE6
  • Fixed a bug in 0.52 that may cause images display incorrect.

What'new in 0.50

  • show image thumb for tidypic,but need a hack of tidypic.Codes gived below.
  • comments and comment form show by default
  • comment pagenation and post use ajax now

TO show image thumb for tidypic,edit tidypic/actions/upload.php,about line 120~130

add

add_to_river('river/object/image/create', 'create', $_SESSION['guid'], $file->guid);

before

} else { //file exceeds file size limit, so delete it
    $file->delete();
    array_push($not_uploaded, $name);

and make sure riverdashboard is below tidypics in the tool admin panel

==========================

Extra view useage:

echo elgg_view('river/item/extra',
                    array('performed_by' => $performed_by,
                        'object' => $object,
                        'body' => $body,
                        'show_comment' => TRUE,)
                    );

in some river item's view.

Examples:

blog/views/default/river/object/blog/create.php

<?php
    /**
     * Show full content of blog in river
     *
     * @package ImprovedRiverDashboard
     */
    /**
     * @author Snow.Hellsing <snow.hellsing@firebloom.cc>
     * @copyright FireBloom Studio
     * @link http://firebloom.cc
     */

    $performed_by = get_entity($vars['item']->subject_guid); // $statement->getSubject();
    $object = get_entity($vars['item']->object_guid);
    $url = $object->getURL();
    
    $url = "<a href=\"{$performed_by->getURL()}\">{$performed_by->name}</a>";
    $summary .= elgg_echo("blog:river:create") . " <a href=\"" . $object->getURL() . "\">" . $object->title . "</a>";
    $toggle = "<div><a onclick=\"$('#blog_details-{$object->guid}').toggle();return false;\" class=\"river_item_toggle_details\" href=\"\">".elgg_echo('toggle_details').'</a></div>';
    $details = "<div id=\"blog_details-{$object->guid}\" class=\"blog_post\" style=\"display:none\">";
    $details .= "<h2>$object->title</h2>";
    $details .= elgg_view('output/longtext',array('value'=>$object->description));
    $details .= '</div>';    

    echo elgg_view('river/item/extra',
                    array('performed_by'=>$performed_by,
                        'object'=>$object,
                        'body'=>$summary.$toggle.$details,
                        'show_comment'=>TRUE));
?>

=======================================================

这是什么?

riverdashboard的修改版

  • 可以在riverdashboard上对一个东西添加评论
  • 列出river上的一个东西已有的评论
  • 让一些东西在river上显示更详细的信息,比如tidypics现在显示缩略图

安装

把riverdashboard和pack_of_roaming_cat这俩文件夹解压到elgg的mod目录下

说明

  • 要让tidypics显示缩略图还需要改动tidypics的一些代码,上面已经给出来了
  • 要让更多种类的river item可以使用评论功能的话,可以去修改它们的river\object\xxx\create视图,上面已经给出了一些示例代码

Here comes the screenshot:

image

ImprovedRiverDashboard riverdashboard

ImprovedRiverDashboard widget

Snow.Hellsing

This cat has travelled far far away and dont know when will come back.I still remember my promises.Sorry,guys.

Stats

  • Category: Uncategorized
  • License: GNU General Public License (GPL) version 2
  • Updated: 2014-11-17
  • Downloads: 35537
  • Recommendations: 5

Other Projects

View Snow.Hellsing's plugins