Probleme de requete avec mysql
Salut a ts,
Bon j'ai trouvé un prob lors de l'insertion ,je crois que c'est un probleme dut de requete car sur le navigateur j'aurais comme resultat d'affichage ""error requete"" de my sql querry .
Un petit aide si c possible et merci
Code:
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 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
| <html>
<head>
<title>Ajouter Opération </title>
</head>
<body>
<h1 align="center">Opération</h1>
<p align="center">(Ajout)</p>
<p align="center">Date <?php $date = date("d-m-Y"); Print(" $date");?> /Heure <?php $heure = date("H:i"); Print(" $heure");?></p>
<?php
if(isset($_POST['Valider']))
{
$hostnamem= "localhost";
$mysql_base = "sms";
$userm = "root";
$passm = "";
$conn=mysql_connect($hostnamem,$userm,$passm) ;
$db=mysql_select_db($mysql_base,$conn) or die ("impossible de se connecter à la base ");
$Nom_C=$_POST['Nom_C'];
$EnvoiAc=$_POST['EnvoiAc'];
$date=$_POST['date'];
$DateF=$_POST['DateF'];
$heure=$_POST['heure'];
$NbrSMS=$_POST['NbrSMS'];
$NumC=$_POST['NumC'];
$Texto=$_POST['Texto'];
$Etat=$_POST['Etat'];
$Ob=$_POST['Ob'];
$ReceptionAc=$_POST['ReceptionAc'];
$Date1=$_POST['Date1'];
$RS=$_POST['RS'];
$requete = "INSERT INTO operation VALUES ('','Nom_C','Envoi','Date','DateF','Heure','Nbr SMS','NumeroC',Texto','Etat','Ob','Reception',Date1','Reponses Justes','idC')";
$res = mysql_query($requete) or die ("error requete");
}
?>
<form action="Ajouter Operation.php" method="post">
<p>Client : <input type="text" name="Nom_C"></p>
<table width="750" border="1" align="left">
<caption>
<div align="left"><strong>Envoi: Activer<input type="radio" name="EnvoiAc" value="Activer"> Désactiver
<input type="radio" name="EnvoiAc" value="Desactive">
</strong></div>
</caption>
<tr>
<th width="49"> Date </th>
<th width="49"> Date1 </th>
<th width="56"> Heure </th>
<th width="68"> Nombre des SMS </th>
<th width="42"> N° Court </th>
<th width="138">Texto</th>
<th width="80">Etat</th>
<th width="183">Observations</th>
</tr>
<tr>
<th><input type="text" name="date"></th>
<th><input type="text" name="DateF"></th>
<td><input type="text" name="heure"></td>
<td><input type="text" name="NbrSMS"></td>
<td><input type="text" name="NumC"></td>
<td><input type="text" name="Texto"></td>
<td><input type="text" name="Etat"></td>
<td><input type="text" name="Ob"></td>
</tr>
</table>
<br></br>
<br></br>
<br></br>
<br></br>
<table width="305" border="1" align="left">
<caption>
<div align="left"><strong>Réception: Activer<input type="radio" name="ReceptionAc" value="Activer"> Désactiver <input type="radio" name="ReceptionAc" value="Desactive"></strong></div>
</caption>
<tr>
<th width="144"> Date </th>
<th width="145">Réponse juste </th>
</tr>
<tr>
<th><input type="text" name="Date1"></th>
<td><input type="text" name="RS"></td>
</tr>
</table>
<br></br>
<br></br>
<br></br>
<p align="center"><input type="submit" name="Valider" value="Valider"/></p><br></br> |