‘;
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’];
$location = $game[‘location’];
$opponent = htmlspecialchars($game[‘oppname’]);
$result = $game[‘result’];
$bgscore = $game[‘score1’];
$oppscore = $game[‘score2’];
$notes = $game[‘notes’];
$story = $game[‘gamestory’];
$goalsfor += $game[‘score1’];
$goalsagainst += $game[‘score2’];
$gamesplayed++;
$gameswon = $game[‘wins’];
echo “
\n”;
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 Goals: $goalsfor |
\n”;
echo “
| Opponent Goals: $goalsagainst |
\n”;
echo “
\n”;
?>