Copyright (C) 2005-2006 James Grant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; see the file COPYING. If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ ?> 'committee_main.php', 'Administration' => 'admin/index.php', 'Judging Score Entry' => 'admin/judging_score_entry.php') ); $project_id = NULL; if($_GET['projectid']) { $project_id = $_GET['projectid']; } else if($_POST['projectid']) { $project_id = $_POST['projectid']; $curr_team = $_POST['score_count']; while($curr_team > 0) { if($_POST["team_" . $curr_team . "_score"] != "") { $score = $_POST["team_" . $curr_team . "_score"]; if($score == 0) { $score = "NULL"; } else { $score = mysql_real_escape_string($score); } mysql_query("UPDATE judges_teams_timeslots_projects_link SET score=" . $score . " WHERE judges_teams_id = " . mysql_real_escape_string($_POST["team_" . $curr_team . "_id"]) . " and projects_id =$project_id and conferences_id={$conference['id']}"); echo mysql_error(); } $curr_team--; } } ?> id]=$r->category; $q=mysql_query("SELECT * FROM projectdivisions WHERE conferences_id='{$conference['id']} ORDER BY id"); $q=mysql_query("SELECT judges_teams_timeslots_projects_link.judges_teams_id, score, judges_teams.num FROM judges_teams_timeslots_projects_link, judges_teams WHERE judges_teams_timeslots_projects_link.judges_teams_id = judges_teams.id AND projects_id = ".mysql_real_escape_string($project_id)." ORDER BY judges_teams_id" ); echo mysql_error(); echo "
"; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; $i = 1; while($r=mysql_fetch_object($q)) { $team=getJudgingTeam($r->judges_teams_id); $teamNames=array_map("teamMemberToName", $team['members']); echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; $i++; } echo "
".i18n("Team Number")."".i18n("Judges")."".i18n("Score")."".i18n("New Score")."
\n"; echo $r->num; echo "judges_teams_id\"/>\n"; echo ""; echo implode(", ", $teamNames); echo "\n"; if($r->score) { echo $r->score; } else { echo "None"; } echo "\n\n"; echo "score\"/>\n"; echo "
\n"; echo "\n"; echo "
\n"; } else { echo i18n("Invalid Project ID."); }