I am trying to update my table row but can't get success.
here is error that coming.
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 'Current_date = '2017-03-30', Content = 'This is first notification te' at line 2
here is my code
if(!empty($_FILES) || isset($_FILES['Details_file'])){
$filetmp = $_FILES["Details_file"]["tmp_name"];
$filename = $_FILES["Details_file"]["name"];
$filetype = $_FILES["Details_file"]["type"];
$filepath = "notification/".$filename;
move_uploaded_file($filetmp, $filepath);
echo $_POST['post_date'];
$stmt = $con1->prepare("UPDATE notification SET
Current_date = '".$_POST['post_date']."',
Content = '".$_POST['Content']."',
File_name= '".$filename."',
File_path ='".$filepath."',
Apply_link = '".$_POST['apply_now']."',
Last_date = '".$_POST['Last_date']."'
WHERE id = '".$_POST['fetch_id']."'") or die(mysqli_error($con1));
$stmt->execute();
$stmt->close();
}
any one can tell me what is problem with my code here.