Add a widget to view

Hi, 

I try to customize my index. I want to have a view like 100% width on top and two columns 50% below. That I managed. On left column I have a list of ten entries activity. In the right column I want the latest blogs and tidypics pictures to appear.

This already works:

$activity = elgg_list_river(array("pagination" => false, "limit" => 10));
echo elgg_view_module('featured', elgg_echo('river:widget:title'), $activity, $mod_params);

echo elgg_view("index/lefthandside");

 

But what would be the code for the blogs and pictures for righthandside column? Can someone please help me out?

  • $blogs = elgg_list_entities(array('type' => 'object', 'subtype' => 'blog', 'limit' => 10, "pagination" => false, 'full_view' => FALSE));
    
    $images = elgg_list_entities(array('type' => 'object', 'subtype' => 'image', 'limit' => 10, "pagination" => false, 'full_view' => FALSE));
    
    echo elgg_view_module('featured', elgg_echo('blogs:widget:title'), $blogs, $mod_params);
    
    echo elgg_view_module('featured', elgg_echo('images:widget:title'), $images, $mod_params);
    
    echo elgg_view("index/righthandside");