Joywork/ajax/deleteEvent.php

15 lines
407 B
PHP
Raw Normal View History

2026-05-22 20:21:54 +02:00
<?php
require_once($_SERVER['DOCUMENT_ROOT']."/config.php");
if (isset($_POST['deleteId'])) {
$post = clearInputData($_POST);
$event_id = $post['deleteId'];
$from = $post['from'];
if ($from == "objects") {
$sql = "DELETE FROM user_object_events WHERE id = $event_id";
} else {
$sql = "DELETE FROM user_client_events WHERE id = $event_id";
}
mysql_query($sql);
}