$id)); if (empty($advanced_filter)) $type = 0; else $type = 1; echo $type; } // Get values of the current netflow filter if ($get_filter_values){ $id = get_parameter('id'); $filter_values = db_get_row_filter ('tnetflow_filter', array('id_sg' => $id)); echo json_encode($filter_values); } return; } // Read filter configuration $filter_id = (int) get_parameter ('filter_id', 0); $filter['id_name'] = (string) get_parameter ('name', ''); $filter['id_group'] = (int) get_parameter ('assign_group', 0); $filter['aggregate'] = get_parameter('aggregate',''); $filter['output'] = get_parameter('output','bytes'); $filter['ip_dst'] = get_parameter('ip_dst',''); $filter['ip_src'] = get_parameter('ip_src',''); $filter['dst_port'] = get_parameter('dst_port',''); $filter['src_port'] = get_parameter('src_port',''); $filter['advanced_filter'] = get_parameter('advanced_filter',''); // Read chart configuration $chart_type = (int) get_parameter('chart_type', 0); $max_aggregates = (int) get_parameter('max_aggregates', 0); $period = (int) get_parameter('period', '86400'); $update_date = (int) get_parameter('update_date', 0); $date = get_parameter_post ('date', date ("Y/m/d", get_system_time ())); $time = get_parameter_post ('time', date ("H:i:s", get_system_time ())); // Read buttons $draw = get_parameter('draw_button', ''); $save = get_parameter('save_button', ''); $update = get_parameter('update_button', ''); // Calculate start and end dates $end_date = strtotime ($date . " " . $time); $start_date = $end_date - $period; //Header ui_print_page_header (__('Netflow live view'), "images/networkmap/so_cisco_new.png", false, "", false, array ()); // Save user defined filter if ($save != '' && check_acl ($config["id_user"], 0, "AW")) { // Save filter args $filter['filter_args'] = netflow_get_filter_arguments ($filter); $filter_id = db_process_sql_insert ('tnetflow_filter', $filter); if ($filter_id === false) { $filter_id = 0; echo '