switch($op) { ... case "all_host_risk": $result = all_host_risk(); break; ... }