query($sql); if ($result->num_rows > 0) { // output data of each row while($row = $result->fetch_assoc()) { $_SESSION["LoggedInUser"] = array($row['uniqueid'],$row['users']); header("location:index.php?result=loggedin"); } $_SESSION["month"] = ''; $_SESSION["month_string"] = ''; $_SESSION["day"] = ''; $_SESSION["day_string"] = ''; } else { header("location:index.php?result=gotrecords"); $_SESSION["accnotfound"] = '