parse_all(); function getSelectOptions($selType, $selValue) { if ($selType == 'REFRESH') { $options = array('0'=>'Stop', '10'=>'10 Seconds','15'=>'15 Seconds', '30'=>'30 Seconds','60'=>'60 Seconds', '120' => '2 minutes', '300' => '5 minutes'); } else if ($selType == 'SHOW_TOP') { $options = array('5'=>'Top 5', '10'=>'Top 10', '20'=>'Top 20', '50'=>'Top 50', '0'=>'All'); } else if ($selType == 'VH_SHOW_SORTBY') { $options = array( 'vhname'=>'Virtual Host Name', 'req_processing'=>'Requests in Processing', 'req_per_sec'=>'Request/Second', 'eap_process'=>'ExtApp Processes', 'eap_inuse'=>'EAProc In Use', 'eap_idle'=>'EAProc Idle', 'eap_waitQ'=>'EAProc WaitQ', 'eap_req_per_sec'=>'EAProc Req/Sec'); } else if ($selType == 'EAP_SHOW_SORTBY') { $options = array( 'vhost'=>'Scope', 'type'=>'Type', 'extapp'=>'Name', 'config_max_conn'=>'Max CONN', 'effect_max_conn'=>'Eff Max', 'pool_size'=>'Pool', 'inuse_conn'=>'In Use', 'idle_conn'=>'Idle', 'waitqueue_depth'=>'WaitQ', 'req_per_sec'=>'Req/Sec'); } return DUtil::genOptions($options, $selValue); } $refresh = DUtil::getGoodVal(DUtil::grab_input("request",'refresh')); $vh_show_ind = DUtil::getGoodVal(DUtil::grab_input("request","vh_show_ind")); $vh_show_top = DUtil::getGoodVal(DUtil::grab_input("request","vh_show_top")); $vh_show_filter = DUtil::getGoodVal(DUtil::grab_input("request","vh_show_filter","string")); $vh_show_sort = DUtil::getGoodVal(DUtil::grab_input("request","vh_show_sort","string")); $eap_show_ind = DUtil::getGoodVal(DUtil::grab_input("request","eap_show_ind")); $eap_show_top = DUtil::getGoodVal(DUtil::grab_input("request","eap_show_top")); $eap_show_filter = DUtil::getGoodVal(DUtil::grab_input("request","eap_show_filter","string")); $eap_show_sort = DUtil::getGoodVal(DUtil::grab_input("request","eap_show_sort","string")); $cur_time = gmdate("D M j H:i:s T"); $server_info = "server {$service->serv['name']} snapshot at $cur_time"; // setting defaults if ($vh_show_ind == '') { $vh_show_ind = 'Show'; } if ($vh_show_top === '') { $vh_show_top = '5'; } if ($vh_show_sort == '') { $vh_show_sort = 'req_per_sec'; } if ($eap_show_ind == '') { $eap_show_ind = 'Show'; } if ($eap_show_top === '') { $eap_show_top = '5'; } if ($eap_show_sort == '') { $eap_show_sort = 'req_per_sec'; } if ($refresh <= 1 && $refresh != 0) { $refresh = 5; } if($refresh >= 2) { echo ''; } ?>