Advertisement
Guest User

Untitled

a guest
Oct 20th, 2017
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 10.89 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html lang="en">
  3.  
  4. <head>
  5.  
  6. <meta charset="utf-8">
  7. <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
  8. <meta name="description" content="">
  9. <meta name="author" content="">
  10.  
  11. <title>TF2Roll.com</title>
  12.  
  13. <link href="vendor/bootstrap/css/bootstrap.min.css" rel="stylesheet">
  14. <link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css">
  15. <link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
  16. <link href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css" rel="stylesheet" />
  17. <link href="css/style.css" type="text/css" rel="stylesheet">
  18. <script src="https://mysqljs.com/mysql.js"></script>
  19.  
  20.  
  21. <style>
  22. body {
  23. padding-top: 54px;
  24. }
  25. @media (min-width: 992px) {
  26. body {
  27. padding-top: 56px;
  28. }
  29. }
  30.  
  31. </style>
  32.  
  33.  
  34. <?php
  35. require 'steamauth/steamauth.php';
  36. include 'mysql/session.php';
  37. ?>
  38. </head>
  39.  
  40. <body>
  41.  
  42. <nav class="navbar navbar-expand-lg fixed-top" style="background-color: #fc5858">
  43. <div class="container">
  44. <a class="navbar-brand" style="color: #ffffff; font-size: 26px" href="index.php">TF2Roll</a>
  45. <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarResponsive" aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
  46. <span class="navbar-toggler-icon"></span>
  47. </button>
  48. <div class="collapse navbar-collapse" id="navbarResponsive">
  49. <ul class="navbar-nav ml-auto">
  50. <li class="nav-item active">
  51. <a class="nav-link" style="color: #ffffff;" href="#">Home
  52. <span class="sr-only">(current)</span>
  53. </a>
  54. </li>
  55. <li class="nav-item">
  56. <a class="nav-link" style="color: #ffffff;" href="support.php">Support</a>
  57. </li>
  58. <li class="nav-item">
  59. <?php if(!isset($_SESSION['steamid'])) { ?>
  60.  
  61. <a class="nav-link" style="color: #ffffff;" href="?login">Login</a>
  62.  
  63. <?php } else { ?>
  64. <li class="nav-item" ><a class="nav-link" style="color: #ffffff;">|</a></li>
  65.  
  66. <div class="w3-dropdown-hover">
  67. <a class="nav-link" style="color: #ffffff;"><?php echo $steamprofile['personaname']; ?></a>
  68. <div class="w3-dropdown-content w3-bar-block w3-card-4">
  69. <a href="#" class="w3-bar-item">Settings</a>
  70. <a href="#" class="w3-bar-item">Credits: <?php echo $credits; ?></a>
  71.  
  72. <a href="?logout" class="w3-bar-item">Logout</a>
  73. </div>
  74. </div>
  75. <?php }?>
  76. </li>
  77. </ul>
  78. </div>
  79. </div>
  80. </nav>
  81.  
  82. <div class="dice-roll">
  83.  
  84. <div class="wrapper">
  85.  
  86. <div class="pd" style="border-radius: 20px; margin: 10px; flex-grow: 1;">
  87. <p style="color: $pb; font-weight: bold;" id="t2" class="cb">CREDITS:</p>
  88. <p style="font-weight: normal" class="cb" id="coinbalance">0</p>
  89. </div>
  90.  
  91.  
  92. <div class="swag" style="margin: 10px; flex-grow: 1;">
  93. <div class="sgm">SELECT WIN PERCENTAGE</div>
  94. <form class="mo">
  95. <label class="gm gmselected" id="gm0">50%<input type="radio" class="gmrb" id="gms0" name="gmode" checked=""></label>
  96.  
  97. <label class="gm" id="gm1">25%<input type="radio" class="gmrb" id="gms1" name="gmode"></label>
  98.  
  99. <label class="gm" id="gm2">10%<input type="radio" class="gmrb" id="gms2" name="gmode"></label>
  100.  
  101. <label class="gm" id="gm3">5%<input type="radio" class="gmrb" id="gms3" name="gmode"></label>
  102.  
  103. </form>
  104. </div>
  105. <div class="gwek" style="margin: 10px; flex-grow: 1;">
  106. <div style="border-radius: 20px; margin: 10px; flex-grow: 1;">
  107. <p id="tf">ROLL UNDER TO WIN</p>
  108.  
  109. <p class="tfs" id="ruw">&lt;5000</p>
  110. </div>
  111. <div class="buff"></div>
  112. <div style="border-radius: 20px; margin: 10px; flex-grow: 1;">
  113. <p id="tf">PAYOUT</p>
  114. <p class="tfs" id="po"> 1.50x</p>
  115. </div>
  116. <div class="buff"></div>
  117. <div style="border-radius: 20px; margin: 10px; flex-grow: 1;">
  118. <p id="tf">CHANCE TO WIN</p>
  119. <p class="tfs" id="ctw">50%</p>
  120. </div>
  121. </div>
  122.  
  123. <div class="col-lg-12 text-center">
  124. <p class="rl" id="rolltag" style="color: rgb(214, 85, 80);">LOSE</p>
  125. <p class="rl" id="roll" style="color: rgb(214, 85, 80);">5000</p>
  126. </div>
  127.  
  128. <div class="iwrapper" style="margin: 10px; flex-grow: 1;">
  129. <input class="input" id="input" value="" style="color: black;">
  130. <div class="bt" style="flex-grow: 1;" id="double">2X</div>
  131. <div class="bt" style="flex-grow: 1;" id="minbet">MIN BET</div>
  132. <div class="bt" style="flex-grow: 1;" id="maxbet" style="border-radius: 0px 5px 5px 0px">MAX BET</div>
  133. </div>
  134. <div class="rbtn" id="rollbutton" style="pointer-events: auto; margin: 10px; flex-grow: 1;"> ROLL THE DICE</div>
  135. </div>
  136. </div>
  137.  
  138. <div class="history">
  139. <table class="table table-bordered">
  140. <thead>
  141. <tr>
  142. <th>Game Hash</th>
  143. <th>Username</th>
  144. <th>Selected Gamemode</th>
  145. <th>Winnings</th>
  146. <th>Roll</th>
  147. </tr>
  148. </thead>
  149. <tbody>
  150. <tr>
  151. <td><?php echo $hash[0]; ?></td>
  152. <td><?php echo $username[0]; ?></td>
  153. <td><?php echo $gamemode[0]; ?></td>
  154. <td><?php echo $winnings[0]; ?></td>
  155. <td><?php echo $roll[0]; ?></td>
  156. </tr>
  157. <tr>
  158. <td><?php echo $hash[1]; ?></td>
  159. <td><?php echo $username[1]; ?></td>
  160. <td><?php echo $gamemode[1]; ?></td>
  161. <td><?php echo $winnings[1]; ?></td>
  162. <td><?php echo $roll[1]; ?></td>
  163. </tr>
  164. <tr>
  165. <td><?php echo $hash[2]; ?></td>
  166. <td><?php echo $username[2]; ?></td>
  167. <td><?php echo $gamemode[2]; ?></td>
  168. <td><?php echo $winnings[2]; ?></td>
  169. <td><?php echo $roll[2]; ?></td>
  170. </tr>
  171. <tr>
  172. <td><?php echo $hash[3]; ?></td>
  173. <td><?php echo $username[3]; ?></td>
  174. <td><?php echo $gamemode[3]; ?></td>
  175. <td><?php echo $winnings[3]; ?></td>
  176. <td><?php echo $roll[3]; ?></td>
  177. </tr>
  178. <tr>
  179. <td><?php echo $hash[4]; ?></td>
  180. <td><?php echo $username[4]; ?></td>
  181. <td><?php echo $gamemode[4]; ?></td>
  182. <td><?php echo $winnings[4]; ?></td>
  183. <td><?php echo $roll[4]; ?></td>
  184. </tr>
  185. </tbody>
  186. </table>
  187. </div>
  188.  
  189. <div class="chatbox">
  190. <script type="text/javascript">
  191. /* most simple ajax chat script (www.linuxuser.at) (GPLv2) */
  192. var nick_maxlength=10;
  193. var http_request=false;
  194. var http_request2=false;
  195. var intUpdate;
  196.  
  197. /* http_request for writing */
  198. function ajax_request(url){http_request=false;if(window.XMLHttpRequest){http_request=new XMLHttpRequest();if(http_request.overrideMimeType){http_request.overrideMimeType('text/xml');}}else if(window.ActiveXObject){try{http_request=new ActiveXObject("Msxml2.XMLHTTP");}catch(e){try{http_request=new ActiveXObject("Microsoft.XMLHTTP");}catch(e){}}}
  199. if(!http_request){alert('Giving up :( Cannot create an XMLHTTP instance');return false;}
  200. http_request.onreadystatechange=alertContents;http_request.open('GET',url,true);http_request.send(null);}
  201. function alertContents(){if(http_request.readyState==4){if(http_request.status==200){rec_response(http_request.responseText);}else{}}}
  202.  
  203. /* http_request for reading */
  204. function ajax_request2(url){http_request2=false;if(window.XMLHttpRequest){http_request2=new XMLHttpRequest();if(http_request2.overrideMimeType){http_request2.overrideMimeType('text/xml');}}else if(window.ActiveXObject){try{http_request2=new ActiveXObject("Msxml2.XMLHTTP");}catch(e){try{http_request2=new ActiveXObject("Microsoft.XMLHTTP");}catch(e){}}}
  205. if(!http_request2){alert('Giving up :( Cannot create an XMLHTTP instance');return false;}
  206. http_request2.onreadystatechange=alertContents2;http_request2.open('GET',url,true);http_request2.send(null);}
  207. function alertContents2(){if(http_request2.readyState==4){if(http_request2.status==200){rec_chatcontent(http_request2.responseText);}else{}}}
  208.  
  209. /* chat stuff */
  210. var show_newmsg_on_bottom=1; /* set to 0 to let new msg´s appear on top */
  211. var waittime=3000; /* time between chat refreshes (ms) */
  212.  
  213. intUpdate=window.setTimeout("read_cont();", waittime);
  214. chatwindow.value = "loading...";
  215.  
  216. function read_cont() { zeit = new Date(); ms = (zeit.getHours() * 24 * 60 * 1000) + (zeit.getMinutes() * 60 * 1000) + (zeit.getSeconds() * 1000) + zeit.getMilliseconds(); ajax_request2("chat.txt?x=" + ms); }
  217. function display_msg(msg1) { chatwindow.value = msg1.trim(); }
  218. function keyup(arg1) { if (arg1 == 13) submit_msg(); }
  219. function submit_msg() { clearTimeout(intUpdate); if (chatnick.value == "") { check = prompt("please enter username:"); if (check === null) return 0; if (check == "") check="..."; chatnick.value=check; } if (chatnick.value.length > nick_maxlength) chatnick.value=chatnick.value.substring(0,nick_maxlength); spaces=""; for(i=0;i<(nick_maxlength-chatnick.value.length);i++) spaces+=" "; v=chatwindow.value.substring(chatwindow.value.indexOf("\n")) + "\n" + chatnick.value + spaces + "| " + chatmsg.value; if (chatmsg.value != "") chatwindow.value=v.substring(1); write_msg(chatmsg.value,chatnick.value); chatmsg.value=""; intUpdate=window.setTimeout("read_cont();", waittime);}
  220. function write_msg(msg1,nick1) { ajax_request("w.php?m=" + escape(msg1) + "&n=" + escape(nick1)); }
  221. function rec_response(str1) { }
  222.  
  223. function rec_chatcontent(cont1) {
  224. if (cont1 != "") {
  225. out1 = unescape(cont1);
  226. if (show_newmsg_on_bottom == 0) { out1 = ""; while (cont1.indexOf("\n") > -1) { out1 = cont1.substr(0, cont1.indexOf("\n")) + "\n" + out1; cont1 = cont1.substr(cont1.indexOf("\n") + 1); out1 = unescape(out1); } }
  227. if (chatwindow.value != out1) { display_msg(out1); }
  228. intUpdate=window.setTimeout("read_cont()", waittime);
  229. }
  230. }
  231. </script>
  232.  
  233. <textarea class="chatcontent" id="chatwindow" rows="19" cols="95" readonly=""></textarea>
  234.  
  235. <div class="iwrapper" style="position: absolute; margin: 10px; flex-grow: 1; bottom: 0;">
  236. <input class="chatinput" id="chatmsg" placeholder="Message..." onkeyup="keyup(event.keyCode);" style="color: black;">
  237. <input type="button" class="bt" style="flex-grow: 1; width: 100px;" value="SEND" onclick="submit_msg();" id="double"></input>
  238. </div>
  239.  
  240. <script src="vendor/jquery/jquery.min.js"></script>
  241. <script src="vendor/popper/popper.min.js"></script>
  242. <script src="vendor/bootstrap/js/bootstrap.min.js"></script>
  243.  
  244. </body>
  245. <script src='https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.0/jquery.min.js'></script>
  246.  
  247. <script>totalcash='<?php echo $credits; ?>'</script>
  248. <script>id='<?php $steamprofile['steamid']; ?>'</script>
  249. <script src="js/dice.js"></script>
  250.  
  251.  
  252. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement