Advertisement
Guest User

Untitled

a guest
Nov 13th, 2018
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.09 KB | None | 0 0
  1. <div class="grid grid-pad">
  2. <?php
  3. /*$getBans = $con->prepare("SELECT * FROM bans WHERE user=? AND active=1");
  4. $getBans->bind_param("i", $_SESSION['id']);
  5. $getBans->execute();
  6. $banRes = $getBans->get_result();
  7. if($banRes->num_rows == 1){
  8. $ban = $banRes->fetch_assoc();
  9.  
  10. $getBanner = $con->prepare("SELECT * FROM users WHERE id=?");
  11. $getBanner->bind_param("i", $ban['person']);
  12. $getBanner->execute();
  13. $banner = $getBanner->get_result()->fetch_assoc();
  14. ?>
  15. <div class="grid grid-pad">
  16. <div class="col-10-12 push-1-12 form ui">
  17. <div class="ui card fluid">
  18. <div class="content">
  19. <div class="header"><h2>
  20. <?php
  21. if($ban['perm'] == "0"){
  22. if(time() - $ban['expires'] >= 0){
  23. $updateBan = $con->prepare("UPDATE bans SET active=0 WHERE user=?");
  24. $updateBan->bind_param("i", $_SESSION['id']);
  25. $updateBan->execute();
  26. ?>
  27. <script>
  28. document.location = "";
  29. </script>
  30. <?php
  31. die();
  32. }*/
  33. ?>
  34. <!--You have been banned. Wait <?=time_elapsed_string2($ban['expires'])?> to be unbanned. -->
  35. <?php
  36. /*
  37. } else {
  38. */
  39. ?>
  40. <!--You have been banned permanently.-->
  41. <?php
  42. //}
  43. ?>
  44. </h2></div>
  45. <div class="ui divider"></div>
  46. <div class="col-8-12">
  47. <h2>Reason:</h2>
  48. <?=nl2br(htmlentities($ban['reason']))?>
  49. </div>
  50. <div class="col-4-12">
  51. <h2>Ban info:</h2>
  52. <p>You were banned by: <?=htmlentities($banner['username'])?></p>
  53. <p>This ban was created <?=time_elapsed_string3($ban['created'])?></p>
  54. </div>
  55. <center>
  56. <?php
  57. if($ban['perm'] == 0){
  58. ?>
  59. <a class="ui button" href="/profiles/logout.php">Logout Here</a>
  60. <?php
  61. } else {
  62. ?>
  63. Thank you for playing.
  64. <?php
  65. }
  66. ?>
  67.  
  68. </center>
  69. </div>
  70. </div>
  71. </div>
  72. </div>
  73. <?php
  74. die();
  75. //}
  76. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement