‘;
exit(‘
Error retrieving games from database!
‘.
‘Error: ‘ . mysql_error() . ‘
‘);
}
echo “
Date |
Opponent |
Location |
Result |
Score |
Notes |
“;
$gamesplayed = 0;
while ($game = mysql_fetch_array($games)) {
$date = $game[‘gamedate’];
$datelink = $game[‘datelink’];
$location = $game[‘location’];
$opponent = htmlspecialchars($game[‘oppname’]);
$result = $game[‘result’];
$bgscore = $game[‘score1’];
$oppscore = $game[‘score2’];
$notes = $game[‘notes’];
$story = $game[‘gamestory’];
$pointsfor += $game[‘score1’];
$pointsagainst += $game[‘score2’];
$gamesplayed++;
$gameswon = $game[‘wins’];
echo “
\n”;
if ($story == Y) {
echo “
$date |
\n”;
} else {
echo “
$date |
\n”;
}
echo “
$opponent |
\n”;
echo “
$location |
\n”;
echo “
$result |
\n”;
echo “
$bgscore-$oppscore |
\n”;
echo “
$notes |
\n”;
echo “
\n”;
}
echo “
\n”;
echo “
\n”;
echo “
Games Played: $gamesplayed |
\n”;
echo “
BGSU Points: $pointsfor |
\n”;
echo “
Opponent Points: $pointsagainst |
\n”;
echo “
\n”;
?>