Update
This commit is contained in:
@@ -41,9 +41,9 @@ class Database
|
||||
return $statement->execute();
|
||||
}
|
||||
|
||||
public function updateQuestion($question, $answer0, $answer1, $answer2, $solution) {
|
||||
$statement = $this->connection->prepare("UPDATE questions SET question=?, answer0 = ?, answer1 = ?, answer2 = ?, solution = ?");
|
||||
$statement->bind_param("ssssi", $question, $answer0, $answer1, $answer2, $solution);
|
||||
public function updateQuestion($id, $question, $answer0, $answer1, $answer2, $solution) {
|
||||
$statement = $this->connection->prepare("UPDATE questions SET question=?, answer0 = ?, answer1 = ?, answer2 = ?, solution = ? WHERE id = ?");
|
||||
$statement->bind_param("ssssii", $question, $answer0, $answer1, $answer2, $solution, $id);
|
||||
return $statement->execute();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user