It is version 2.05. Does this need to be updated?
This is the full code of the page:
<?php require_once('../../Connections/athletics2.php'); ?>
<?php require_once('../../webassist/mysqli/authentication.php'); ?>
<?php require_once('../../webassist/mysqli/rsobj.php'); ?>
<?php require_once('../../webassist/mysqli/queryobj.php');
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
?>
<?php
if ("" == "") {
$RestrictAccess = new WA_MySQLi_Auth();
$RestrictAccess->Action = "restrict";
$RestrictAccess->Name = "admins";
$RestricAccessRedirect = "error.php";
if (function_exists("rel2abs")) $RestricAccessRedirect = $RestricAccessRedirect?rel2abs($RestricAccessRedirect,dirname(__FILE__)):"";
$RestrictAccess->FailRedirect = $RestricAccessRedirect;
$RestrictAccess->execute();
}?>
<?php
$athlete = new WA_MySQLi_RS("athlete",$athletics2,0);
$athlete->setQuery("SELECT *, athlete_registrations.athleteID as theathlete, athlete_registrations.seasonID as theseason FROM athlete_registrations left join athletes on athletes.athleteID = athlete_registrations.athleteID left join medication on athlete_registrations.athleteID = medication.athleteID left join sports on athlete_registrations.sportID = sports.sportID WHERE athlete_registrations.seasonID = ? group by athlete_registrations.athleteID order by submitted_date desc");
$athlete->bindParam("i", "".(isset($_GET['seasonID']) ?$_GET['seasonID']:"") ."", "-1"); //colname
$athlete->execute();?>
<?php
$season = new WA_MySQLi_RS("season",$athletics2,1);
$season->setQuery("SELECT * FROM season WHERE seasonID = ?");
$season->bindParam("i", "".(isset($_GET['seasonID'])?$_GET['seasonID']:"") ."", "-1"); //colname
$season->execute();
?>
<?php
if (isset($_POST["submit"]) || isset($_POST["submit_x"])) {
$MultipleUpdateConnection = $athletics2;
$MultipleUpdateTable = "athlete_registrations";
$MultipleUpdateRedirect = "edit_office_fields.php?seasonID=".($athlete->getColumnVal("theseason")) ."";
$MultipleUpdateIndexColumn = "registrationID";
$MultipleUpdateIndexColumnType = "d";
$MultipleUpdateIdentifier = "WADA_RepeatID_registrationID";
for ($x=0; $x<sizeof($_POST[$MultipleUpdateIdentifier]); $x++) {
$MultipleUpdateCount = $_POST[$MultipleUpdateIdentifier][$x];
$UpdateQuery = new WA_MySQLi_Query($MultipleUpdateConnection);
$UpdateQuery->Action = "update";
$UpdateQuery->Table = $MultipleUpdateTable;
$UpdateQuery->bindColumn("level4", "s", "".((isset($_POST["level4"."_".$MultipleUpdateCount]))?$_POST["level4"."_".$MultipleUpdateCount]:"") ."", "WA_IGNORE");
$UpdateQuery->bindColumn("physical_date", "t", "".((isset($_POST["physical_date"."_".$MultipleUpdateCount]))?$_POST["physical_date"."_".$MultipleUpdateCount]:"") ."", "WA_IGNORE");
$UpdateQuery->bindColumn("concussion_course2", "t", "".((isset($_POST["concussion_course2"."_".$MultipleUpdateCount]))?$_POST["concussion_course2"."_".$MultipleUpdateCount]:"") ."", "WA_IGNORE");
$UpdateQuery->bindColumn("academic", "s", "".((isset($_POST["academic"."_".$MultipleUpdateCount]))?$_POST["academic"."_".$MultipleUpdateCount]:"") ."", "WA_IGNORE");
$UpdateQuery->bindColumn("impact_testing_date", "t", "".((isset($_POST["impact_testing_date"."_".$MultipleUpdateCount]))?$_POST["impact_testing_date"."_".$MultipleUpdateCount]:"") ."", "WA_IGNORE");
$UpdateQuery->bindColumn("other_medical_info", "s", "".((isset($_POST["other_medical_info"."_".$MultipleUpdateCount]))?$_POST["other_medical_info"."_".$MultipleUpdateCount]:"") ."", "WA_IGNORE");
$UpdateQuery->addFilter($MultipleUpdateIndexColumn, "=", $MultipleUpdateIndexColumnType, $MultipleUpdateCount);
$UpdateQuery->execute();
}
if ($MultipleUpdateRedirect) {
if (function_exists("rel2abs")) $MultipleUpdateRedirect = rel2abs($MultipleUpdateRedirect,dirname(__FILE__));
header("location: " . $MultipleUpdateRedirect);
}
}?>
<script src="//code.jquery.com/jquery-1.10.2.js"></script>
<link rel="stylesheet" href="/resources/demos/style.css">
<script src="//code.jquery.com/ui/1.11.4/jquery-ui.js">
</script>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script type="text/javascript" src="../lib/site.js"></script>
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>CRLS Athletic Registration System</title>
<link href="../text_athletics_admin.css" rel="stylesheet" type="text/css">
<style type="text/css">
td img {margin: 0;}
table.sortable th:not(.sorttable_sorted):not(.sorttable_sorted_reverse):not(.sorttable_nosort):after {
content: " \25B4\25BE"
}
table.sortable tbody tr:nth-child(2n) td {
background: #cccccc;
}
table.sortable tbody tr:nth-child(2n+1) td {
background: #ccfffff;
}
</style>
<script src="//code.jquery.com/jquery-1.11.3.min.js"></script>
<script src="https://cdn.datatables.net/1.10.8/js/jquery.dataTables.min.js"></script>
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.10.8/css/jquery.dataTables.min.css" />
<script type="text/javascript" class="init">
$(document).ready(function() {
$('#example').DataTable( {
"order": [[ 0, "desc" ]]
} );
} );
</script>
<style type="text/css">
body {
background-color: #e8e5de;
}
</style>
</head>
<body><form method="post">
<div class="container">
<div class="side">
<div class="header">
<h2>CRLS Athletic Registration System</h2>
</div>
<h3><?php echo($season->getColumnVal("season")); ?> Athletes</h3> <form method="post">
<table height="300px" width="100%" border="0" cellspacing="2" cellpadding="8">
<tr>
<td height="10" align="center" valign="middle" bgcolor="#CCCCCC"><a href="manage-sports.php">Manage Sports</a> | <a href="manage_positions.php">Manage Positions</a> | <a href="manage_seasons.php">Manage Seasons</a> | <a href="manage_coaches.php">Manage Coaches</a> | <a href="manage_athletes.php">Manage Athletes</a> | <a href="manage_policies.php">Manage Policies </a> | <a href="change_password.php">Change Your Password</a> | <a href="manage_admin_accounts.php">Manage Admin Accounts</a> | <a href="reports.php">Reports</a></td>
</tr>
<tr>
<td height="10" valign="top" bgcolor="#00A499"><strong><font color="#FFFFFF">Enter the Athlete Info Below
<input type="submit" name="submit" id="submit" value="SAVE DATA">
</font></strong></td>
</tr>
<tr>
<td valign="top" align="center">
<table width="100%" border="0" cellspacing="3" id="example" cellpadding="5" class="display">
<thead>
<tr>
<th valign="top">Submitted Date</th>
<th valign="top">Last Name</th>
<th valign="top">First Name</th>
<th valign="top">Student ID#</th>
<th valign="top">Sport</th>
<th valign="top">Level</th>
<th valign="top">Physical Date</th>
<th valign="top">Concussion Course</th>
<th valign="top">Academic</th>
<th valign="top">IMpact Testing</th>
<th valign="top">Other Medical Info</th>
<th valign="top"> </th>
</tr>
</thead>
<tbody>
<?php
$wa_repeatfor = -1; // Repeat Selection 1
if (!isset($wa_repeatcount)) $wa_repeatcount = 0;
while (!$athlete->atEnd() && $wa_repeatfor != 0) {
$wa_repeatfor--;
$wa_repeatcount++;
if (!$athlete->atEnd()) {
?>
<tr>
<td valign="top"> <?php echo(date("m/d/Y", strtotime($athlete->getColumnVal("submitted_date")))); ?></td>
<td valign="top"><?php echo($athlete->getColumnVal("student_lname")); ?></td>
<td valign="top"><?php echo($athlete->getColumnVal("student_fname")); ?></td>
<td valign="top"><?php echo($athlete->getColumnVal("studentID")); ?>
<input type="hidden" name="WADA_RepeatID_registrationID[]" id="WADA_RepeatID_registrationID_<?php echo($athlete->getColumnVal("registrationID")); ?>" value="<?php echo($athlete->getColumnVal("registrationID")); ?>" /></td>
<td valign="top"><?php echo($athlete->getColumnVal("sport_name")); ?></td>
<td valign="top"><label for="level4"></label>
<select name="level4_<?php echo($athlete->getColumnVal("registrationID")); ?>" id="level4_<?php echo($athlete->getColumnVal("registrationID")); ?>">
<option value="" <?php if (!(strcmp("", ($athlete->getColumnVal("level4"))))) {echo "selected=\"selected\"";} ?>></option>
<option value="Varsity" <?php if (!(strcmp("Varsity", ($athlete->getColumnVal("level4"))))) {echo "selected=\"selected\"";} ?>>Varsity</option>
<option value="JV" <?php if (!(strcmp("JV", ($athlete->getColumnVal("level4"))))) {echo "selected=\"selected\"";} ?>>JV</option>
<option value="Freshman" <?php if (!(strcmp("Freshman", ($athlete->getColumnVal("level4"))))) {echo "selected=\"selected\"";} ?>>Freshman</option>
</select></td>
<td valign="top"><label for="physical_date"></label> <input name="physical_date_<?php echo($athlete->getColumnVal("registrationID")); ?>" type="date" id="physical_date_<?php echo($athlete->getColumnVal("registrationID")); ?>" value="<?php echo($athlete->getColumnVal("physical_date")); ?>"></td></td>
<td valign="top"><label for="concussion_course2"></label>
<input name="concussion_course2_<?php echo($athlete->getColumnVal("registrationID")); ?>" type="date" id="concussion_course2_<?php echo($athlete->getColumnVal("registrationID")); ?>" value="<?php echo($athlete->getColumnVal("concussion_course2")); ?>"></td>
<td valign="top"><label for="academic"></label>
<input name="academic_<?php echo($athlete->getColumnVal("registrationID")); ?>" type="text" id="academic_<?php echo($athlete->getColumnVal("registrationID")); ?>" value="<?php echo($athlete->getColumnVal("academic")); ?>"></td>
<td valign="top"><label for="impact_testing_date"></label>
<input name="impact_testing_date_<?php echo($athlete->getColumnVal("registrationID")); ?>" type="date" id="impact_testing_date_<?php echo($athlete->getColumnVal("registrationID")); ?>" value="<?php echo($athlete->getColumnVal("impact_testing_date")); ?>"></td>
<td valign="top"><label for="other_medical_info"></label>
<?php
if ("".($athlete->getColumnVal("medical_comments")) ."" > "0") { // WebAssist Show If
?>
<br><?php echo($athlete->getColumnVal("medical_comments")); ?>
<?php
} // ("".($athlete->getColumnVal("medical_comments")) ."" > "0")
?>
<?php
if ("".($athlete->getColumnVal("medical_conditions_comments")) ."" > "0") { // WebAssist Show If
?>
<br><?php echo($athlete->getColumnVal("medical_conditions_comments")); ?>
<?php
} // ("".($athlete->getColumnVal("medical_conditions_comments")) ."" > "0")
?>
<?php
if ("".($athlete->getColumnVal("serious_conditions_comments")) ."" > "0") { // WebAssist Show If
?>
<br><?php echo($athlete->getColumnVal("serious_conditions_comments")); ?>
<?php
} // ("".($athlete->getColumnVal("serious_conditions_comments")) ."" > "0")
?>
<?php
if ("".($athlete->getColumnVal("traumatic_head_injury_comments")) ."" > "0") { // WebAssist Show If
?>
<br><?php echo($athlete->getColumnVal("traumatic_head_injury_comments")); ?>
<?php
} // ("".($athlete->getColumnVal("traumatic_head_injury_comments")) ."" > "0")
?>
<?php
if ("".($athlete->getColumnVal("medical_conditions_comments")) ."" > "0") { // WebAssist Show If
?>
<br><?php echo($athlete->getColumnVal("medical_attention_comments")); ?>
<?php
} // ("".($athlete->getColumnVal("medical_conditions_comments")) ."" > "0")
?>
<br><?php
if ("".($athlete->getColumnVal("concussion_comments")) ."" > "0") { // WebAssist Show If
?>
<?php echo($athlete->getColumnVal("concussion_comments")); ?>
<?php
} // ("".($athlete->getColumnVal("concussion_comments")) ."" > "0")
?>
<textarea name="other_medical_info_<?php echo($athlete->getColumnVal("registrationID")); ?>" id="other_medical_info_<?php echo($athlete->getColumnVal("registrationID")); ?>" cols="30" rows="3"><?php echo($athlete->getColumnVal("other_medical_info")); ?></textarea></td>
<td align="right" valign="top"><font size="-1"><a href="view_athlete_registration.php?athleteID=<?php echo($athlete->getColumnVal("theathlete")); ?>®istrationID=<?php echo($athlete->getColumnVal("registrationID")); ?>&seasonID=<?php echo((isset($_GET["seasonID"]))?$_GET["seasonID"]:"") ?>">View</a>
<?php
if ("".(($athlete->getColumnVal("no_meds"))) ."" == NULL ) { // WebAssist Show If
?>
<br>
<a href="view_athlete_registration.php?athleteID=<?php echo($athlete->getColumnVal("theathlete")); ?>®istrationID=<?php echo($athlete->getColumnVal("registrationID")); ?>&seasonID=<?php echo((isset($_GET["seasonID"]))?$_GET["seasonID"]:"") ?>"><img src="../images/med.png" alt="Takes Meds" width="36" height="39" border="0"></a>
<?php
} // ("".(($athlete->getColumnVal("no_meds"))) ."" == NULL")
?>
</font></td>
</tr>
<?php
$athlete->moveNext(); // Repeat Alternate 1
} else {
?>
<?php
} // End Repeat Alternate 1
?>
<?php
}
if (!isset($wa_startindex)) $athlete->moveFirst(); // End Repeat Selection 1
?>
</tbody>
</table>
</td>
</tr>
</table>
<div class="header"><p align="center"><font color="#FFFFFF">Cambridge Rindge & Latin School | <a href="http://crls.cpsd.us" target="_blank"><font color="#FFFFFF">crls.cpsd.us</font></a> | 617.349.6690</font></p></div>
</div>
</div></form>
</body>
</html>