query("SELECT pseudo FROM login WHERE pseudo = '$pseudo' AND mdp = '$password'"); $count = $requete->rowCount(); if($count == 1) { session_start(); $_SESSION['pseudo'] = $_POST['pseudo']; $reponse = "v"; } else { $reponse = "i"; } } echo json_encode($reponse);