index.php 594 B

123456789101112131415161718192021222324
  1. <?php
  2. // Init
  3. error_reporting(NULL);
  4. session_start();
  5. include($_SERVER['DOCUMENT_ROOT']."/inc/main.php");
  6. // Check token
  7. if ((!isset($_GET['token'])) || ($_SESSION['token'] != $_GET['token'])) {
  8. header('location: /login/');
  9. exit;
  10. }
  11. if($_GET['delete'] == 1){
  12. $v_id = (string)((int)$_GET['notification_id']);
  13. v_exec('v-delete-user-notification', [$user, $v_id]);
  14. } else {
  15. $v_id = (string)((int)$_GET['notification_id']);
  16. //echo VESTA_CMD."v-acknowledge-user-notification ".$v_username." ".$v_id;
  17. v_exec('v-acknowledge-user-notification', [$user, $v_id]);
  18. }
  19. exit;