You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
505 B
26 lines
505 B
<?php
|
|
|
|
|
|
class Modele {
|
|
|
|
function afficherQuestions(){
|
|
$db = new SqliteDb();
|
|
//$db->createTable();
|
|
$qg = new QuestionsGateway($db);
|
|
|
|
$tabQuestions = $qg->afficherQuestions();
|
|
return $tabQuestions;
|
|
}
|
|
|
|
function connection($id, $mdp){
|
|
$ug = new UserGateway(new SqliteDb());
|
|
$vraiMdp = $ug->getPassword($id);
|
|
if(!password_verify($mdp, $vraiMdp)){
|
|
return null;
|
|
}
|
|
return 1;
|
|
}
|
|
|
|
|
|
}
|