O have gone though the list of similar error and I didn't see the one that works with mine. Am out of time on this job but can still get it. am not an expert yet on php, please I need help on the code below.
$db = mysqli_connect("localhost", "joy", "hvkgigkgijhkhi");
if(!$db){
echo "No DB";
}else{
$query = "SELECT * FROM member WHERE uname= '$uname'";
mysqli_select_db("testing",$db);
$results = mysqli_query($query);
if(!$results){
die('Could not connect: ' . mysqli_connect_error());
}else{
while ($row = mysqli_fetch_array($results,MYSQL_ASSOC)) {
//$row.$_SESSION['uname'] = $uname;
$row.$_SESSION['fullname'] = $Fname;
$row.$_SESSION['my_ref_id'] = $My_ref;
//$row.$_SESSION['email'] = $email;
//$_SESSION['success'] = "You are now logged in";
//header('location: index.php');
}
}
}
?>
<!-- logged in user information -->
<div class="menue">
<?php if (isset($_SESSION['uname'])) : ?>
<p>Refferal Pin: <strong><?php echo $My_ref; ?></strong><br></p>
<p>Full Name: <strong><?php echo $_SESSION['fullname']; ?></strong><br></p>
<p>User Name: <strong><?php echo $_SESSION['uname']; ?></strong><br></p>
<p>Email Address: <strong><?php echo $_SESSION['email']; ?></strong><br></p>
<p> <a href="index.php?logout='1'" style="color: red;">logout</a> </p>
<?php endif ?>
</div>