you can now edit, add and delete results
This commit is contained in:
@@ -10,6 +10,13 @@
|
||||
$stmt->bindParam(1, $_POST["m_id"], PDO::PARAM_INT);
|
||||
$stmt->bindParam(2, $_POST["s_id"], PDO::PARAM_INT);
|
||||
$stmt->execute();
|
||||
if(get_direct_points($con, $_POST['s_id'])->fetch()['direkte_punkte'] == 0) {
|
||||
$stmt = $con->prepare("DELETE FROM Ergebnisse WHERE m_id = ? AND s_id =?");
|
||||
$stmt->bindParam(1, $_POST["m_id"], PDO::PARAM_INT);
|
||||
$stmt->bindParam(2, $_POST["s_id"], PDO::PARAM_INT);
|
||||
$stmt->execute();
|
||||
update_points($con, $_POST["s_id"]);
|
||||
}
|
||||
} catch(PDOException $e) {
|
||||
handle_pdo_exception($e);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user