Load only the submenus under given menu How to get ONLY the list of Submenus under given menu programmatically. Say, the given menu means a main-menu item. I tried with menu_tree_page_data. But not sure if I can use it to select only the required menus.

The scenario is, I have active menu loaded using menu_get_active_trail(). So I have all the details of the main menu. Now with those details I need to get the submenus under that.
$main_menu_tree = menu_tree('main-menu');
foreach ($main_menu_tree as $key =&gt; &amp;$main_menu_item) {
    if (is_numeric($key)) {
        $main_menu_item['#below']['#theme_wrappers'][0] = 'some_other_theme_wrapper';
    }
}
print drupal_render($main_menu_tree);


If you have array of main menu active trails you can use foreach to loop through the array print menus and their sub menus.