index.php 661 B

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. error_reporting(NULL);
  3. $TAB = 'FIREWALL';
  4. // Main include
  5. include($_SERVER['DOCUMENT_ROOT']."/inc/main.php");
  6. // Check user
  7. if ($_SESSION['user'] != 'admin') {
  8. header("Location: /list/user");
  9. exit;
  10. }
  11. // Header
  12. include($_SERVER['DOCUMENT_ROOT'].'/templates/header.html');
  13. // Panel
  14. top_panel($user,$TAB);
  15. // Data
  16. v_exec('v-list-firewall', ['json'], false, $output);
  17. $data = json_decode($output, true);
  18. $data = array_reverse($data, true);
  19. include($_SERVER['DOCUMENT_ROOT'].'/templates/admin/list_firewall.html');
  20. // Back uri
  21. $_SESSION['back'] = $_SERVER['REQUEST_URI'];
  22. // Footer
  23. include($_SERVER['DOCUMENT_ROOT'].'/templates/footer.html');