function taxonomy_menu_get_term_sets_by_group in Taxonomy menu 6.3
get a list of the term sets for a group
Parameters
$mglid: menu group id
2 calls to taxonomy_menu_get_term_sets_by_group()
- taxonomy_menu_group_form in ./
taxonomy_menu.admin.inc - Implementation of hook_form().
- taxonomy_menu_group_list in ./
taxonomy_menu.admin.inc - page callback for admin/build/taxonomy_menu @TODO Turn this into a theme function
File
- ./
taxonomy_menu.admin.inc, line 757 - admin section for taxonomy menu
Code
function taxonomy_menu_get_term_sets_by_group($mgid) {
$output = array();
$result = db_query('SELECT * FROM {taxonomy_menu_group_term_set} WHERE mgid = %d', $mgid);
while ($data = db_fetch_object($result)) {
// Split up the parent tsid and tid
list($ptsid, $ptid) = explode(':', $data->parent_item);
$output[$data->tsid] = taxonomy_menu_get_term_set($data->tsid);
$output[$data->tsid]->parent = taxonomy_menu_get_term_set($ptsid);
}
return $output;
}