开发者

Drupal - get $primary_links with nested menus as php array

开发者 https://www.devze.com 2023-01-14 12:33 出处:网络
I\'m trying to get a PHP array that includes a simple nested list of primary_links and their sub-menu items. This seems like a simple task but I can\'t seem to get a straight answer on how exactly to

I'm trying to get a PHP array that includes a simple nested list of primary_links and their sub-menu items. This seems like a simple task but I can't seem to get a straight answer on how exactly to do it.

From there I would theme it exactly as needed.

Thanks!开发者_JAVA百科


This seemed to do the trick!

menu_tree_all_data('primary-links')


Did you try this function? menu_primary_links();

0

精彩评论

暂无评论...
验证码 换一张
取 消