Menu
I’ve looked at the PHP.net manual, searched Google and I can’t find any examples of updating records with prepared statements. Everything is on select and insert…
How is it done?
I tried the following, but it says I have a syntax error from the first line of code…
[code=php]$q = “UPDATE table1 SET title=?, description=? date=? WHERE id=?”;
$stmt = mysqli_prepare($dbc, $q);
mysqli_stmt_bind_param($stmt, ‘sssi’, $title, $descrip, $date1, $id);
mysqli_stmt_execute($stmt);