Bonsoir
J'ai un souci d'appel avec cette requete :
Code php : 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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50 <?php // récupération des données du formulaire de connexion $mdp=$_POST['mdp']; $pseudo=$_POST['pseudo']; $db = mysql_connect('localhost', 'root', ''); mysql_select_db('projet',$db); $sql= 'SELECT nom , prenom , age , mail , tel , adresse , paiement FROM CLIENT WHERE mdp='.$mdp.'and pseudo='.$pseudo; $req = mysql_query($sql) or die ('ERREUR '.mysql_error()); $data = mysql_fetch_array($req); echo " Bienvenue sur votre compte <br>"; echo " <table> <tr> <td> NOM </td> "; echo " <td> Prenom </td> "; echo " <td> Age </td> "; echo " <td> Adresse </td> "; echo " <td> Telephone </td> "; echo " <td> Mail </td> "; echo " <td> Mod de paiement </td> "; echo " </tr> "; echo " <tr> <td>" ; echo $data['nom']; echo "</td> "; echo " <td>" ; echo $data['prenom']; echo "</td> "; echo " <td>" ; echo $data['age'] ; echo "</td> "; echo " <td>" ; echo $data['adresse']; echo "</td> "; echo " <td>" ; echo $data['tel']; echo "</td> "; echo " <td>"; echo $data['mail']; echo " </td> "; echo " <td> " ; echo $data['paiement'] ; echo " </td> "; echo " </tr> </table> "; ?>
J'ai le message d'erreur suivant :
J'ai verifié le code une bonne douzaine de fois est tout à l'air bon ou alors j'ai zappé un truc ?ERREUR You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'pseudo=pomme and num_cli=num_cli' at line 1
Merci d'avance si quelqu'un peut me dépanner
Partager