fetchArray("SELECT * FROM `zz_gruppi` WHERE `id`='" . $id_record . "'"); function menuSelection($element, $depth, $perms_values, $perms_names) { global $dbo; global $rootdir; global $id_module; global $id_record; $depth ++; $name = ($element['name2'] != '') ? $element['name2'] : $element['name']; $submenus = $dbo->fetchArray("SELECT * FROM zz_modules WHERE enabled='1' AND parent='" . $element['id'] . "' AND `type`='menu' ORDER BY `order` ASC"); if ($submenus != null && count($submenus) != 0) { $temp = ""; foreach ($submenus as $submenu) { $temp .= menuSelection($submenu, $depth, $perms_values, $perms_names); } } $result .= ' ' . str_repeat("     ", $depth) . $name . ' ' . $temp; return $result; } ?>