Hi guys,
Me again, I have just noticed something which i cant figure out whats going on. Below the query pulls back and account type from my db however the result which is coming back does have the account type but has a number 1 after it
eg: Current Account Type: Premium1
I just want Premium to come back which is what is in the DB.
Does any one know what is happening. Im sure its going to be my code.
$sql = "SELECT account FROM accounts WHERE ID='". $_SESSION['member_ID'] ."'";
$result = mysql_query($sql);
if (!$result) {
echo "Could not successfully run query ($sql) from DB: " . mysql_error();
exit;
}
if (mysql_num_rows($result) == 0) {
echo "No rows found, nothing to print so am exiting";
exit;
}
while ($row = mysql_fetch_assoc($result))
{
echo $row["account"];
}