Advertisement
Guest User

#ask How To Add Progges bar ?

a guest
Nov 16th, 2018
126
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 5.66 KB | None | 0 0
  1. <?php
  2. error_reporting(0);
  3. ob_start('ob_gzhandler');
  4. session_start();
  5.  
  6. $username = '@#';
  7. $password = '@#';
  8.  
  9. function pac($str) {
  10.     echo $str;
  11. }
  12. pac("
  13. <style>
  14. @import url('https://fonts.googleapis.com/css?family=Cabin');
  15. *{
  16.     padding: 0;
  17.     margin: 0;
  18.     box-sizing:border-box;
  19. }
  20. body {
  21.     margin:auto;
  22.     background: #191919;
  23.     font-family: 'Cabin';
  24.    -webkit-font-smoothing:antialiased;
  25.     font-size: 14px;
  26.    color:#fff;
  27.    text-shadow:0px 0px 0px #343436;
  28. }
  29. *:focus {
  30.     outline: 0;
  31. }
  32. .latar {
  33.    
  34.     background:#222;
  35.     color:#fff;
  36.     box-shadow:0px 1px 1px rgba(0,0,0,0.1) inset;
  37.     border-radius:5px;
  38.        text-align: center;
  39. }
  40. input[type=text], input[type=password] {
  41.     padding:7px;
  42.     font-size:14px;
  43.     font-family: 'Cabin';
  44.     width:100%;
  45.     border:1px solid #343436;
  46.     background:none;
  47.     color: #FA5A5A;
  48. }
  49. input[type=text]:hover, input[type=password]:hover {
  50.     border:1px solid #FA5A5A;
  51.     transition: all 0.5s;
  52. }
  53. button {
  54.     padding:7px;
  55.     font-size:14px;
  56.     font-family: 'Cabin';
  57.     background:#FA5A5A;
  58.     width:100px;
  59.     border:1px solid #FA5A5A;
  60. }
  61. button:hover {
  62.     background:none;
  63.     color:#FA5A5A;
  64.     border:1px solid #FA5A5A;
  65.     transition: all 0.5s;
  66. }
  67. .top5 {
  68.     margin-top: 5px;
  69. }
  70.  
  71. hr {
  72.     border: 0;
  73.     height: 1px;
  74.     background-image: -webkit-linear-gradient(left, #FA5A5A, #FA5A5A, #FA5A5A);
  75.     background-image: -moz-linear-gradient(left, #FA5A5A, #FA5A5A, #FA5A5A);
  76.     background-image: -ms-linear-gradient(left, #FA5A5A, #FA5A5A, #FA5A5A);
  77.     background-image: -o-linear-gradient(left, #FA5A5A, #FA5A5A, #FA5A5A);
  78. }
  79. h3 {
  80.     font-weight:500;
  81. }
  82. </style></head></body>");
  83. function form() {
  84.     pac('<div class="container"><div class="latar"><center><form action="" method="post">
  85.     <table>
  86. <td>Username :</td>
  87.     <td><input name="user" type="text"></td><tr>
  88. <td>Password :</td>
  89.     <td><input name="pass" type="password"></td>
  90.     <tr>
  91.     <td></td><td><button name="login">Login!</button></td></table>
  92.     </form></center></div></div>');
  93. }
  94. pac("<script>
  95.    baseUrl = window.location.href.split('?')[0];
  96.    window.history.pushState('name', '?', baseUrl);
  97. </script>");
  98. if(isset($_GET['out'])) {
  99.     setcookie('UNDERXPLOIT', time() - 3600);
  100.     unset($_SESSION['username']);
  101. }
  102. pac('<div class="container">');
  103. if(isset($_POST['login'])) {
  104. if($_POST['user'] == $username AND $_POST['pass'] == $password) {
  105.     $_SESSION['username'] = $username;
  106.     $_COOKIE[$username] = $password;
  107.     setcookie('UNDERXPLOIT', md5($_SERVER['HTTP_HOST']));
  108. } else if(empty($_POST['user']) || empty($_POST['pass'])) {
  109.     pac('<div class="content">Form Can\'t be  Empty !!</div>');
  110. } else {
  111.     pac('<div class="content">Invalid Username or Password !!</div>');
  112.     }
  113. }
  114. pac('<center><br><h3>Upload Download File</h3><br><hr><br></center>');
  115. if($_SESSION['username'] == $username) {
  116.     pac('<!DOCTYPE html>
  117. <html>
  118. <head>
  119.   <meta name="viewport" content="width=1024">
  120. <!-- Bootstrap CSS -->
  121. <!-- Bootstrap DataTables CSS -->
  122. <!-- Jquery -->
  123. <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
  124. <script type="text/javascript" language="javascript" src="http://code.jquery.com/jquery-1.10.2.min.js"></script>
  125. <!-- Jquery DataTables -->
  126. <script type="text/javascript" language="javascript" src="http:////cdn.datatables.net/1.10.4/js/jquery.dataTables.min.js"></script>
  127. <!-- Bootstrap dataTables Javascript -->
  128. <script type="text/javascript" language="javascript" src="http://cdn.datatables.net/plug-ins/9dcbecd42ad/integration/bootstrap/3/dataTables.bootstrap.js"></script>
  129. <style>
  130. body {
  131.     margin:auto;
  132.     background: #191919;
  133.     font-family: "Cabin";
  134.    -webkit-font-smoothing:antialiased;
  135.     font-size: 14px;
  136.    color:#fff;
  137.    text-shadow:0px 0px 0px #343436;
  138. }
  139. .kiri {
  140. text-align: left;
  141. }
  142. .kanan {
  143. text-align: right;
  144. }
  145. </style>
  146.  
  147. <title>Upload Download File</title>
  148. <script type"text/javascript">
  149. var viewMode = getCookie("view-mode");
  150. if(viewMode == "desktop"){
  151.    viewport.setAttribute("content", "width=1024");
  152. }else if (viewMode == "mobile"){
  153.    viewport.setAttribute("content", "width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=no");
  154. }
  155. </script>
  156.  
  157. <!-- Panggil Fungsi -->
  158. <script type="text/javascript" charset="utf-8">
  159.    $(document).ready(function() {
  160.     $(".table-paginate").dataTable();
  161. } );
  162. </script>
  163.  
  164. </head>
  165.  
  166. <body><br><br><br><strong>
  167. <center><div class="kanan"><a href="?out">./LOGOUT</a><br></div>
  168. <div class="kiri"><?php
  169. <br>
  170. <form enctype="multipart/form-data" action="uploader.php" method="post">
  171. Choose a file to upload: <input name="uploadedfile" type="file" id="fileupload" /><br />
  172. <input type="submit" value="Upload File" class="btn btn-primary btn-sm" />
  173. </form></div>
  174.          
  175. </center>
  176. <br/>
  177. <div class"container">
  178. <table class="table table-bordered table-dark table-paginate" cellspacing="0" width="100%"> <thead><tr>
  179. <th>File Name</th>
  180. <th>Upload Date</th>
  181. <th>Type</th>
  182. <th>Size</th>
  183. <th>Delete</th>
  184. </tr>
  185. </thead>');
  186.  
  187. if ($handle = opendir('./s/'))
  188. {   while (false !== ($file = readdir($handle)))
  189.     {   if($file!=="." && $file !=="..")
  190.     {   echo "<tr><td><a href=\"download.php?id=" . urlencode($file). "\">$file</a></td>";
  191.         echo "<td>" . date ("d/m/Y H:i", filemtime("s/".$file)) . "</td>";
  192.         echo "<td>" . pathinfo("s/".$file, PATHINFO_EXTENSION) . " file </td>";
  193.         echo "<td>" . round(filesize("s/".$file)/1024) . " KB</td>";
  194.         echo "<td><a href=\"hapus.php?id=$file\">Del</a></td></tr>";
  195.         }
  196.     }
  197.     closedir($handle);
  198. }
  199. pac('
  200. </table>
  201. </div>
  202. </body>
  203. </html>');
  204.     } else {
  205.         form();
  206.     }
  207. pac("<br><hr></div></div>");
  208. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement