index.php 660 B

123456789101112131415161718192021222324252627282930
  1. <?php
  2. session_start();
  3. $TAB = 'PACKAGE';
  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. exec (VESTA_CMD."v-list-user-packages json", $output, $return_var);
  17. $data = json_decode(implode('', $output), true);
  18. unset($output);
  19. include($_SERVER['DOCUMENT_ROOT'].'/templates/admin/list_packages.html');
  20. // Back uri
  21. $_SESSION['back'] = $_SERVER['REQUEST_URI'];
  22. // Footer
  23. include($_SERVER['DOCUMENT_ROOT'].'/templates/footer.html');