db_select($query); $smarty->assign("vlan_id", $vlan_id); $smarty->assign("vlan_name", $vlan[0]['vlan_name']); $smarty->assign("vlan_number", $vlan[0]['vlan_number']); // setup subnet $query = "SELECT s.subnet_id, s.subnet_address, s.subnet_mask FROM subnetvlan AS v LEFT JOIN subnet AS s USING(subnet_id) WHERE v.vlan_id=" . $vlan_id . " ORDER BY INET_ATON(s.subnet_address)"; $subnets = $db->db_select($query); foreach ($subnets as $subnet) { $subnet_options[$subnet['subnet_id']] = $subnet['subnet_address'].'/'.$subnet['subnet_mask']; } $smarty->assign("subnet_options", $subnet_options); $smarty->display("vlansubnetdel.tpl"); include("footer.php"); ?>