index.php 661 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. session_start();
  3. $TAB = 'IP';
  4. error_reporting(NULL);
  5. // Main include
  6. include($_SERVER['DOCUMENT_ROOT']."/inc/main.php");
  7. // Header
  8. include($_SERVER['DOCUMENT_ROOT'].'/templates/header.html');
  9. // Panel
  10. top_panel($user,$TAB);
  11. // Data
  12. if ($_SESSION['user'] == 'admin') {
  13. exec (VESTA_CMD."v-list-sys-ips json", $output, $return_var);
  14. $data = json_decode(implode('', $output), true);
  15. $data = array_reverse($data, true);
  16. unset($output);
  17. include($_SERVER['DOCUMENT_ROOT'].'/templates/admin/list_ip.html');
  18. }
  19. // Back uri
  20. $_SESSION['back'] = $_SERVER['REQUEST_URI'];
  21. // Footer
  22. include($_SERVER['DOCUMENT_ROOT'].'/templates/footer.html');