From 85a3df0a63b80d22f43a70fc9dc988e2903a3d40 Mon Sep 17 00:00:00 2001 From: mauirixxx Date: Wed, 17 May 2017 23:38:01 -1000 Subject: [PATCH] fixed sql query to actually get playerid --- gw-toon.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gw-toon.php b/gw-toon.php index 03c8487..a79f153 100644 --- a/gw-toon.php +++ b/gw-toon.php @@ -4,7 +4,7 @@ $con = new mysqli(DATABASE_HOST, DATABASE_USER, DATABASE_PASS, DATABASE_NAME); if ($con->connect_errno > 0){ die ('Unable to connect to database [' . $db->connect_errno . ']'); } -$sql = "SELECT charname FROM `playername` WHERE `userid` = '1' ORDER BY `charname` ASC"; //need to make userid a variable +$sql = "SELECT playerid, charname FROM `playername` WHERE `userid` = '1' ORDER BY `charname` ASC"; //need to make userid a variable if (!$result = $con->query($sql)){ die ('There was an error running the query [' . $con->error . ']'); }