Nice bit of code that shows how many rows were deleted, if any!
Note: If the data to be written is the same it will show “0 records added”
echo $sql = "UPDATE todolist SET list = '$movetolist' WHERE item = '$itemtext' ";
if ($mysqli->query($sql) === TRUE) {
echo "New record created successfully";
} else {
echo "Error: " . $sql . "
" . $sql->error;
}
echo "Affected rows: " . $mysqli -> affected_rows;












