Ok voilà ce que j'ai fait :
$result2=mysql_query(sprintf("INSERT INTO complaint(Description, Complaint_reception_date, Incident_Request_number, Natco, LOS, Complainant_name, Recording_date, Recording_time, Complaint_year, Complaint_number, Status, Recorded_by) VALUES ('$DateRec',\'%s\','$IncNb','$Natco','$Los','$CompName','$CurrentDate','$CurrentTime','$CurrentYear','$NbC','Opened','$User')",mysql_real_escape_string("$Desc", "$lien"),"$DateRec", "$IncNb","$Natco","$Los","$CompName","$CurrentDate","$CurrentTime","$CurrentYear","$NbC",'Opened',"$User"));
Et voilà mon erreur :
Warning: mysql_real_escape_string() expects parameter 2 to be resource, string given in c:\home\easyphp1-8\www\treatcreate.php on line 66
Partager