$y"); while ($res = mysql_fetch_object($result)) { $server_state[$res->server_state] += 1; if ($res->server_state == 5) { $outcome[$res->outcome] += 1; if ($res->outcome == 3) { $client_state[$res->client_state] += 1; } } } mysql_free_result($result); start_table(); echo "Server state# results\n"; for ($ss=1; $ss<6; $ss++) { if ($server_state[$ss] == 0) { $x = "0"; } else { $x = "".$server_state[$ss].""; } row2(result_server_state_string($ss), $x); } echo ""; echo "Outcome of 'Over' results# results\n"; for ($ro=0; $ro<6; $ro++) { if ($outcome[$ro] == 0) { $x = "0"; } else { $x = "".$outcome[$ro].""; } $h = result_outcome_string($ro); $color = outcome_color($ro); echo "$h$x\n"; } echo ""; echo "Client state of 'Client error' results# results\n"; for ($cs=1; $cs<6; $cs++) { if ($client_state[$cs] == 0) { $x = "0"; } else { $x = "".$client_state[$cs].""; } row2(result_client_state_string($cs), $x); } end_table(); page_tail(); ?>