Editing Front Page Demo

I would like to add Discussion Topics and Pages to the displayed page.

How do I do that?

  • You should use your custom plugin.

    Copy from /mod/custom_index/views/default/custom_index/content.php

    to /mod/my_plugin/views/default/custom_index/content.php

    And add the blocks:

    // discussions
    if (elgg_is_active_plugin('discussions')) {
           $discussions_params = $list_params;
           $discussions_params['subtype'] = 'discussion';
           echo elgg_view_module('featured',  elgg_echo('collection:object:discussion'), elgg_list_entities($discussions_params));
    // pages
    if (elgg_is_active_plugin('pages')) {
         $pages_params = $list_params;
         $pages_params['subtype'] = 'page';
         echo elgg_view_module('featured',  elgg_echo('collection:object:page'), elgg_list_entities($pages_params));
    You can use this skeleton plugin (Elgg 3).
    Read this topic also.
    Learn more on the docs.