From 81ae4cb1eb3eb3dc859b38d00c7c9d7700216e95 Mon Sep 17 00:00:00 2001 From: Patrick Davison Date: Mon, 19 Mar 2012 19:22:01 -0700 Subject: Fixed some Syntax errors --- includes/mapoftheday.php | 2 +- includes/maps.php | 13 ++++++------- 2 files changed, 7 insertions(+), 8 deletions(-) (limited to 'includes') diff --git a/includes/mapoftheday.php b/includes/mapoftheday.php index 1f3140f..f12c6d8 100644 --- a/includes/mapoftheday.php +++ b/includes/mapoftheday.php @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/includes/maps.php b/includes/maps.php index a6787a7..37eae5f 100644 --- a/includes/maps.php +++ b/includes/maps.php @@ -45,22 +45,22 @@ function DisplayMap($mapMatrix, $idprefix = 1, $style = 'normal', $speed = NULL) //TP2 case 'm': $maptable .= "
"; break; - case 'n': $maptable .= " + case 'n': $maptable .= "
"; break; //TP3 case 'g': $maptable .= "
"; break; - case 'h': $maptable .= " + case 'h': $maptable .= "
"; break; //TP4 case 'i': $maptable .= "
"; break; - case 'j': $maptable .= " + case 'j': $maptable .= "
"; break; //TP5 case 'k': $maptable .= "
"; break; - case 'l': $maptable .= " + case 'l': $maptable .= "
"; break; case 'a': case 'b': case 'c': case 'd': case 'e': @@ -702,15 +702,14 @@ function formSolution($solution) { //Returns the best solution. function getSolution($userID, $mapID) { include_once('db.inc.php'); - $sql = "SELECT `solution` + $sql = "SELECT `solution`, `moves` FROM `solutions` WHERE `userID` = '$userID' AND `mapID` = '$mapID' "; $result = mysql_query($sql); if (mysql_num_rows($result) > 0) { - list($solution) = mysql_fetch_row($result); - return $solution; + return mysql_fetch_assoc($result); } } -- cgit v1.2.3