我的SQLi UPDATE查询似乎没有起作用,我几乎尝试了所有内容,但我不知道哪里出错了。我创建了一个类似的样式PHP但是用于注册一个人(使用INSERT)并且工作正常。这是我的更新代码:
<?php
$con=mysqli_connect("localhost","my_user","my_password","my_db");
$firstname= $_POST["firstname"];
$surname = $_POST["surname"];
$info= $_POST["info"];
$statement = mysqli_prepare("UPDATE `People` SET `firstname`=? , `surname`=? , `info`=? WHERE `personid`=79 ");
mysqli_stmt_bind_param($statement, "sss", $firstname, $surname, $info);
mysqli_stmt_execute($statement);
mysqli_stmt_close($statement);
mysqli_close($con);
?>