Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By capitolium on
Hi all,
I have a question: I need to put in a page's content the PHP code for all the children of a menu item.
For example, if I have the following menu structure:
Item 1
|_ Item 1.1
|_ Item 1.2
Item 2
|_ Item 2.1
|_ Item 2.2
|_ Item 2.3
|_ Item 2.4
Item 3
|_ Item 3.1
|_ Item 3.2
|_ Item 3.3
how can I access all the children of Item 2 so that I can print them in any style I want to a new page content?
I think the menus are array structures, but my PHP knowledge is very limited so in the menu module I cannot find nothing useful.
Thank you.
Lubli
Comments
menu_get_menu()
The function menu_get_menu() retrieves the menu:
http://api.drupal.org/api/4.7/function/menu_get_menu
--
~/.singatrue: file not found
Thank you
Thank you