| 0 comments ]

The river is an activity stream containing descriptions of activities. In new elgg there is a plugin called “riverdashboard” , And you can add river for your plugins too.Each river may be added after an activity such as add delete etc .You can use the following function for doing this.

add_to_river($viewname,$actionname,$userguid,$entityguid);

The first parameter $viewname is the name of the view that will display the river item and the next one $actionname is the action and the other two parameters are the guid of the user performing the action, and the guid of the entity being acted on.

Elgg recommends the view location of the river views as follows /river/classname/event, where classname is the class you’re interested in (ElggObject for objects, ElggUser for users, and so on) and event is the event (create, update, delete and so on).

River item information will be passed in an object called $vars['item'], which contains two important parameters $vars['item']->subject_guid that is the user guid and the action guid that is the $vars['item']->object_guid .

0 comments

Post a Comment

Please put your comments here. your questions, your suggestions, also what went wrong with me.