\n"; $display = FALSE; } if ($display && isset ($_GET["election_id"]) && is_numeric ($_GET["election_id"])) $election_id = $_GET["election_id"]; else { $election_id = -1; $error .= "Please choose an election/referendum on this list.
\n"; $display = FALSE; } if ($display && $election_id >= 0) { $election = elec_get_election ($handle, $election_id); if ($election === FALSE) { $error .= "The specified election/referendum does not exist.
\n"; $display = FALSE; } else if (!elec_election_has_ended ($election)) { $error .= "The voting period for the specified ".htmlspecialchars(elec_election_get_type ($election))." starts on ".htmlspecialchars($election["voting_start"])." (UTC) and ends on ".htmlspecialchars($election["voting_end"])." (UTC). It is not possible to see the results now.
\n"; $display = FALSE; } else { $results = elec_get_results($handle, $election_id); } } if (isset ($election) && $election !== FALSE) { if ($results !== FALSE) { echo "

Results for the ".htmlspecialchars($election["name"])."

\n"; } else { $error .= "The voting period for the specified ".htmlspecialchars(elec_election_get_type ($election))." has closed, but the results of the election have not yet been calculated. It is not possible to see the results now.
\n"; echo "

In the meantime, you can look at the list of all votes and verify that your vote is correct.

\n"; $display = FALSE; } } if ($display) { echo "
"; echo htmlspecialchars($results["result"]); echo "
"; echo "

Please look at the list of all votes and verify that your vote is correct.

\n"; } if (isset ($error) && $error != "") { echo "
".$error."
\n";; echo "

If you don't understand the error, you should probably contact the Membership and Elections Committee, which can be reached at elections@gnome.org.

\n"; } if (isset ($handle)) elec_sql_close ($handle); ?>