Bonjour
Je ne comprends pourquoi je n'obtiens aucun résultat, il n'y a d'erreur signalées mais rien ne s'affiche, page blanche, aiez_moi svp:
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31 <?php // On vérifie si la variable existe et sinon elle vaut NULL $recup_pays = $_POST['pays'] ? $_POST['pays'] : NULL; $recup_region = $_POST['region'] ? $_POST['region'] : NULL; $recup_ville = $_POST['ville'] ? $_POST['ville'] : NULL; $recup_code_postal = $_POST['code_postal'] ? $_POST['code_postal'] : NULL; $req = $base->query(' SELECT * FROM team WHERE pays = "'.$recup_pays.'" OR region = "'.$recup_region.'" OR ville = "'.$recup_ville.'" OR code_postal = "'.$recup_code_postal.'" ORDER BY nom ') ; while($data = $req->fetchAll()){ echo $data['nom']."<br />\n"; echo $data['prenom']."<br />\n"; } $req->closeCursor(); ?>
Partager