Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $conn = new mysqli('localhost','user','password','db');
- $sql = "SELECT Status FROM Users WHERE Username = '".$_GET["username"]."'
- AND Password = '".$_GET["password"]."'";
- $result = $conn->query($sql);
- if ($result->num_rows > 0) {
- while($row = $result->fetch_assoc()) {
- // This is where it is giving the error
- echo $row['Status'] ;
- }
- } else {
- echo "0 results";
- }
- $conn->close();
Add Comment
Please, Sign In to add comment