From 4f953bb0f8a6d6be805a08020f729fa363d46a2c Mon Sep 17 00:00:00 2001 From: mauirixxx Date: Wed, 17 May 2017 23:52:05 -1000 Subject: [PATCH] if the toonhas no data, let someone know --- gw-pull.php | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/gw-pull.php b/gw-pull.php index 74d368f..5e080f5 100644 --- a/gw-pull.php +++ b/gw-pull.php @@ -10,12 +10,16 @@ if (!$result = $con->query($sql)){ die ('There was an error running the query [' . $con->error . ']'); } while ($row = $result->fetch_array()){ - echo 'On ' . $row['historydate'] . ', "' . $row['charname'] . '" got ' . $row['goldrec'] . 'GP and '; - if (is_null($row['material'])) { - echo 'a ' . $row['itemrarity'] . ' req' . $row['itemreq'] . ' ' . $row['itemattribute'] . ' ' . $row['itemtype'] . ' named something stupid
'; + if ($row['charname'] == ''){ + echo 'No data available for $cnameid'; } else { - echo 'a ' . $row['material'] . '!
'; - } //add another else statement to cover RUNES here + echo 'On ' . $row['historydate'] . ', "' . $row['charname'] . '" got ' . $row['goldrec'] . 'GP and '; + if (is_null($row['material'])) { + echo 'a ' . $row['itemrarity'] . ' req' . $row['itemreq'] . ' ' . $row['itemattribute'] . ' ' . $row['itemtype'] . ' named something stupid
'; + } else { + echo 'a ' . $row['material'] . '!
'; + } //add another else statement to cover RUNES here + } } ?>