} if ($_POST) { if ($_POST['container']) { $name = htmlspecialchars(trim($_POST['container'])); } } if ($name) { //Get the object from the 7rules list $container = $layer7_rules_list[$name]; } if ($_GET) { switch ($action) { case "add": $show_proto_form = true; $container = new layer7(); $sform = $container->build_form(); //constructs the graphical interface on the right side unset($container); break; case "show": $show_proto_form = true; if ($container) { $sform = $container->build_form(); } else { $show_proto_form = false; $input_errors[] = gettext("Layer7 Rules Container not found!"); } break; default: echo log_error("Get default"); $show_proto_form = false;
} if ($_POST) { if ($_POST['container']) { $name = htmlspecialchars(trim($_POST['container'])); } } if ($name) { //Get the object from the 7rules list $container = $layer7_rules_list[$name]; } if ($_GET) { switch ($action) { case "add": $show_proto_form = true; $container = new layer7(); $output_form .= $container->build_form(); //constructs the graphical interface on the right side unset($container); break; case "show": $show_proto_form = true; if ($container) { $output_form .= $container->build_form(); } else { $show_proto_form = false; $input_errors[] = gettext("Layer7 Rules Container not found!"); } break; default: echo log_error("Get default"); $show_proto_form = false;