Advertisement
Guest User

Untitled

a guest
Oct 21st, 2017
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.45 KB | None | 0 0
  1. <html>
  2. <style>
  3. /* Consolidation of fonts (*shielf your eyes, there are many of them!). Families, then sizes and weights */
  4.  
  5. /* Families */
  6. html {
  7. font-size: 100%;
  8. }
  9.  
  10. body {
  11. font-family: "Roboto", Arial, Helvetica, sans-serif;
  12. font-size: 13px;
  13. }
  14.  
  15. /*
  16. h1 {font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;}
  17. h2 {font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;}
  18. h3 {font-family: Arial, Helvetica, sans-serif;}
  19. h4 {font-family: "Trebuchet MS", Verdana, Helvetica, Arial, Sans-serif;}
  20. .pagination li.active span {font-family: "Open Sans", "Droid Sans", Verdana, Arial, Helvetica;}
  21. .dropdown-extended .header {font-family: Arial, "Helvetica Neue", Helvetica, Arial, sans-serif;}
  22. .notification_list p.notifications_title {font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;}
  23. .button {font-family: "Open Sans", "Droid Sans", Verdana, Arial, Helvetica;}
  24. li.header dt, li.header dd {font-family: Arial, Helvetica, sans-serif;}
  25. .postbody h3 {font-family: "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif;}
  26. .content {font-family: "Lucida Grande", "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif;}
  27. .content p {font-family: "Lucida Grande", "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif;}
  28. dl.faq {font-family: "Lucida Grande", Verdana, Helvetica, Arial, sans-serif;}
  29. p.author {font-family: Verdana, Helvetica, Arial, sans-serif;}
  30. .notice {font-family: "Lucida Grande", Verdana, Helvetica, Arial, sans-serif;}
  31. .attachbox dt {font-family: Arial, Helvetica, sans-serif;}
  32. dl.file {font-family: Verdana, Arial, Helvetica, sans-serif;}
  33. dl.file dt {font-family: Verdana, Arial, Helvetica, sans-serif;}
  34. dl.thumbnail dd {font-family: Verdana, Arial, Helvetica, sans-serif;}
  35. fieldset.polls {font-family: "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif;}
  36. fieldset.polls dd div {font-family: Arial, Helvetica, sans-serif;}
  37. fieldset {font-family: Verdana, Helvetica, Arial, sans-serif;}
  38. input {font-family: Verdana, Helvetica, Arial, sans-serif;}
  39. select {font-family: Verdana, Helvetica, Arial, sans-serif;}
  40. select optgroup option {font-family: Verdana, Helvetica, Arial, sans-serif;}
  41. textarea {font-family: "Lucida Grande", Verdana, Helvetica, Arial, sans-serif;}
  42. .message-box textarea {font-family: "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif;}
  43. a.button1, input.button1, input.button3, a.button2, input.button2 {font-family: "Lucida Grande", Verdana, Helvetica, Arial, sans-serif;}
  44. a.forumtitle {font-family: "Trebuchet MS", Helvetica, Arial, Sans-serif;}
  45. a.topictitle {font-family: "Trebuchet MS", Helvetica, Arial, Sans-serif;}
  46. */
  47.  
  48.  
  49.  
  50. /* Everything Else */
  51.  
  52. h1 {
  53. /* Forum name */
  54. font-weight: 600;
  55. font-size: 18px;
  56. color: white;
  57. background-color: #FFA62F;
  58. }
  59.  
  60. h2 {
  61. /* Forum header titles */
  62. font-weight: 300;
  63. font-size: 2em;
  64. }
  65.  
  66. h3 {
  67. /* Sub-headers (also used as post headers, but defined later) */
  68. font-weight: 500;
  69. font-size: 1.2em;
  70. }
  71.  
  72. h4 {
  73. /* Forum and topic list titles */
  74. font-size: 1.3em;
  75. }
  76.  
  77. p {
  78. font-size: 1.1em;
  79. }
  80.  
  81. b, strong {
  82. font-weight: 1000;
  83. }
  84.  
  85. i, em {
  86. font-style: italic;
  87. }
  88.  
  89.  
  90.  
  91.  
  92. .box-blue {
  93. margin:0 0 25px;
  94. overflow:hidden;
  95. padding:10px;
  96. background-color:#FFA62F;
  97. border:1px solid #FFA62F;
  98. -webkit-border-radius: 5px;
  99. border-radius: 5px;
  100. color: white;
  101. }
  102.  
  103. .box-gray {
  104. margin:0 0 25px;
  105. overflow:hidden;
  106. padding:2px;
  107. background-color:#e8e8e8;
  108. border:1px solid #e8e8e8;
  109. -webkit-border-radius: 5px;
  110. border-radius: 5px;
  111. }
  112.  
  113. .box-red {
  114. margin:0 0 25px;
  115. overflow:hidden;
  116. padding:2px;
  117. background-color:#ffcccc;
  118. border:1px solid #ffcccc;
  119. -webkit-border-radius: 5px;
  120. border-radius: 5px;
  121. }
  122.  
  123.  
  124.  
  125.  
  126.  
  127. .box-green {
  128. margin:0 0 25px;
  129. overflow:hidden;
  130. padding:20px;
  131. width:35%;
  132. background-color:#ffe4b2;
  133. border:1px solid #ffe4b2;
  134. -webkit-border-radius: 5px;
  135. border-radius: 5px;
  136. }
  137.  
  138.  
  139. </style>
  140. <title>HTML with PHP</title>
  141. <body>
  142.  
  143.  
  144.  
  145.  
  146. <div class="box-gray"><img src="http://dynbans.com/images/bansymbal.png"><font color="red"> <b>10 Recent Bans</b></font>
  147.  
  148.  
  149. </div>
  150.  
  151. <?php
  152. require_once("include/geoip.inc");
  153.  
  154. $servername = "localhost";
  155.  
  156. $username = "dsadsa";
  157.  
  158. $password = "dasdsa";
  159.  
  160. $dbname = "dadsa";
  161.  
  162.  
  163.  
  164.  
  165.  
  166. // Create connection
  167.  
  168. $conn = new mysqli($servername, $username, $password, $dbname);
  169.  
  170. // Check connection
  171.  
  172. if ($conn->connect_error) {
  173.  
  174. die("Connection failed: " . $conn->connect_error);
  175.  
  176. }
  177.  
  178.  
  179.  
  180. $sql = "SELECT player_ip,player_nick,ban_reason,admin_nick FROM dynbans_freshbans.amx_bans WHERE expired=0 ORDER BY bid desc LIMIT 10";
  181.  
  182. $result = $conn->query($sql);
  183.  
  184.  
  185.  
  186. if ($result->num_rows > 0) {
  187. $gi = geoip_open($config->path_root."/include/GeoIP.dat",GEOIP_STANDARD);
  188. // output data of each row
  189. echo '<table cellpadding="2" frame="box" rules="all" summary="">';
  190. echo '<thead><tr><th><h1>Player</h1></th><th><h1>Reason</h1></th><th><h1>Admin</h1></th></tr></thead><tbody>';
  191. while($row = $result->fetch_assoc()) {
  192. $cc = "";
  193. if(!empty($row["player_ip"])) {
  194. $cc = geoip_country_code_by_addr($gi, $row["player_ip"]);
  195. }
  196. echo "<tr><td>" . '<img alt="" src="images/country/' . ( !empty($cc) ? echo strtolower($cc) : echo 'clear' ) . '.png" /> ' . htmlspecialchars(substr($row["player_nick"],0,11)) . "</td><td>" . htmlspecialchars(substr($row["ban_reason"],0,11)) . "</td><td>" . htmlspecialchars(substr($row["admin_nick"],0,11)) . "</td></td>";
  197. }
  198. echo '</tbody></table>';
  199. } else {
  200. echo "0 results";
  201. }
  202.  
  203. geoip_close($gi);
  204. $conn->close();
  205.  
  206. ?>
  207.  
  208. </div>
  209.  
  210. </body>
  211. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement