Advertisement
Guest User

Untitled

a guest
May 29th, 2015
271
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.32 KB | None | 0 0
  1. <?php
  2. /**
  3. *
  4. * @ This file is created by deZender.Net
  5. * @ deZender (PHP5 Decoder for SourceGuardian & phpSHIELD)
  6. *
  7. * @ Version : 1.1.6.0
  8. * @ Author : DeZender
  9. * @ Release on : 02.06.2013
  10. * @ Official site : http://DeZender.Net
  11. *
  12. */
  13.  
  14. if (!( defined( 'BASEPATH' ))) {
  15. exit( 'No direct script access allowed' );
  16. (bool)true;
  17. }
  18.  
  19. class Admin extends LS_Controller {
  20. public function __construct() {
  21. parent::__construct( );
  22.  
  23. if (!$this->users->logged_in( )) {
  24. $this->users->redirect_to_login( );
  25. } else {
  26. if (!$this->users->is_admin( )) {
  27. redirect( '' );
  28. }
  29. }
  30.  
  31. $this->page = 'configure';
  32. $nodes = array( );
  33. $result = $this->elasticsearch->query( 'node', array( 'size' => 2000 ) );
  34.  
  35. if (0 < $result['_shards']['total']) {
  36. foreach ($result['hits']['hits'] as $n) {
  37. if ($n['_id'] == 'global') {
  38. continue;
  39. }
  40.  
  41. $nodes[$n['_source']['hostname']] = $n;
  42. }
  43. }
  44.  
  45. ksort( &$nodes );
  46. $this->leftbar_data['nodes'] = $nodes;
  47. }
  48.  
  49. public function index() {
  50. $this->load->model( 'systemstat' );
  51. $css = array( '/css/elastichq.css' );
  52. $this->init_page( _( 'Admin Dashboard' ), $this->page, array( ), $css );
  53. ............................................................
  54. ...................................
  55. .................
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement