Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
QUESTION menu_data() documentation
#6
The function is coded in admin\inc\theme_functions.php

In essence it returns a single array if the menu data for a single page is requested:
$specific = array("slug"=>$slug,"url"=>$url,"parent_slug"=>$parent,"title"=>$title,"menu_priority"=>$pri,"menu_text"=>$text,"menu_status"=>$menuStatus,"private"=>$private,"pub_date"=>$pubDate);

or an array of arrays for all pages in menu_sorted order if not:
foreach ($pagesSorted as $page) {
.....
$menu_extract[] = $specific;
}
return $menu_extract;

If the xml flag is set true, the info comes back as xml.

Hope that helps someone else. It's really important to have good documentation for newcomers, particularly if you are aiming to appeal because of being simple
Reply


Messages In This Thread
menu_data() documentation - by drking - 2020-05-01, 04:31:31
RE: menu_data() documentation - by craiga - 2020-05-01, 20:26:14
RE: menu_data() documentation - by drking - 2020-05-02, 04:33:27
RE: menu_data() documentation - by Felix - 2020-05-02, 05:57:32
RE: menu_data() documentation - by drking - 2020-05-02, 06:59:46
RE: menu_data() documentation - by drking - 2020-05-03, 00:33:00



Users browsing this thread: 1 Guest(s)