Advertisement
Guest User

Untitled

a guest
Aug 15th, 2018
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.36 KB | None | 0 0
  1. <?php
  2. include_once("../database.php");
  3. $db = new database;
  4.  
  5. class login{
  6.     public $username;
  7.     public $password;
  8.  
  9.     function check_login(){
  10.         $query = mysqli_query($db -> db_connect, "SELECT * FROM login WHERE username='" . $this -> username . "' AND password='" . $this -> password . "'");
  11.         if($query){
  12.             return 1;
  13.         }else{
  14.             return 0;
  15.         }
  16.     }
  17. }
  18. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement