patch
This commit is contained in:
parent
29f4115c62
commit
f71dee1791
2 changed files with 23 additions and 15 deletions
6
api.php
6
api.php
|
@ -43,6 +43,9 @@
|
|||
|
||||
case 'rechercher':
|
||||
|
||||
|
||||
if(isset($_SESSION["utilisateur_authentifie"]) && ($_SESSION["utilisateur_authentifie"] == 1)){
|
||||
|
||||
// Exemple URL: /api.php/chercher?req=math&duree=30&themes=algebre,geometrie
|
||||
|
||||
$query = isset($_GET["req"]) ? $_GET["req"] : "";
|
||||
|
@ -57,7 +60,10 @@
|
|||
echo json_encode(["status" => "0", "msg" => $e->getMessage()]);
|
||||
}
|
||||
|
||||
}else{
|
||||
echo json_encode(["status" => "1", "resultats" => []]);
|
||||
|
||||
}
|
||||
break;
|
||||
|
||||
case 'decomposer_ensemble':
|
||||
|
|
|
@ -63,8 +63,10 @@
|
|||
<div class="barre-recherche centre-horizontal">
|
||||
<form id="recherche_form">
|
||||
<input class="champ" type="text" id="recherche_input" placeholder="Rechercher une fiche, annale ...">
|
||||
<div hidden>
|
||||
<label class="champ" for="tout-les-insa-switch">Activer la recherche sur tout les INSA</label>
|
||||
<input class="champ checkbox" type="checkbox" id="tout_les_insa_switch">
|
||||
</div>
|
||||
<input hidden type="submit">
|
||||
<input hidden class="champ" type="text" id="themes_input" placeholder="themes (appuyez sur la touche entrée entre chaque thèmes)">
|
||||
<input hidden class="champ" type="number" id="duree_input" placeholder="durée en minutes">
|
||||
|
|
Loading…
Reference in a new issue