index.php 682 B

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