Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public function selectLogin($userName, $password){
- $link= Connect::getConnect();
- $user= new User();
- $userName= $user->setUserName($userName);
- $password= $user->setPassword($password);
- $sql= "SELECT (username, password)
- FROM User
- WHERE username = :username AND password = :password";
- $param= array(':username'=>$user->getUserName(),
- ':password'=>$user->getPassword());
- try {
- $stmt= $link->prepare($sql);
- $stmt->execute($param);
- // A execução da consulta está retornando false!
- var_dump($stmt->execute($param));
- $query = $stmt->fetchAll(PDO::FETCH_ASSOC);
- } catch (PDOException $e){
- $e->getLine();
- $e->getMessage();
- } catch (Exception $e) {
- $e->getMessage();
- }
- }
Add Comment
Please, Sign In to add comment