Fix wrong function call.
This commit is contained in:
parent
1a19776abd
commit
f718e3747d
|
@ -86,10 +86,10 @@ function add_requirement() {
|
|||
die("Connection failed: " . $conn->connect_error);
|
||||
}
|
||||
$stmt = $conn->prepare("DELETE FROM req where id = ?;");
|
||||
$stmt->bind('s', $item_id);
|
||||
$stmt->bind_param('s', $item_id);
|
||||
$stmt->execute();
|
||||
$stmt = $conn->prepare("INSERT INTO req (id, name, quantity) VALUES (?,?,?);");
|
||||
$stmt->bind('ssi', $item_id, $item_name, $quantity);
|
||||
$stmt->bind_param('ssi', $item_id, $item_name, $quantity);
|
||||
$stmt->execute();
|
||||
$conn->close();
|
||||
send_html("Added to requirements");
|
||||
|
@ -106,7 +106,7 @@ function deposit(){
|
|||
die("Connection failed: " . $conn->connect_error);
|
||||
}
|
||||
$stmt = $conn->prepare("UPDATE req set quantity = quantity - ? where id = ?;");
|
||||
$stmt->bind('is', $item_id, $quantity);
|
||||
$stmt->bind_param('is', $item_id, $quantity);
|
||||
$stmt->execute();
|
||||
$conn->close();
|
||||
send_html("Deposited!");
|
||||
|
|
Loading…
Reference in New Issue