Guest User

Untitled

a guest
Jun 24th, 2018
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.14 KB | None | 0 0
  1. <body bgcolor = 'black'>
  2. <?php
  3. $host = "localhost";
  4. $user = "chickenx";
  5. $pass = "niglet4676";
  6. $dbname = "chickenx_samp";
  7. $dbtable = "samp_users";
  8. $con = mysql_connect($host, $user, $pass);
  9. mysql_select_db($dbname, $con);
  10.  
  11. $result = mysql_query("SELECT * FROM samp_users WHERE `Banned` = '1' ORDER BY LastLogin DESC LIMIT 0, 100");
  12. $all = mysql_query("SELECT * FROM samp_users WHERE `Banned` = '1'");
  13. $users = mysql_num_rows($all);
  14. if ($users == 0)
  15. {
  16. echo "<center><font color='red'>There are currently <b>no</b> banned users.</font></center>";
  17. }
  18. else {
  19. echo "<center><font color='red'>There are a total of <b><u>".$users."</u></b> banned users, showing <b><u>100</u></b> of the most recent bans.</font></center>";
  20. while($row = mysql_fetch_array($result))
  21. {
  22. if ($row['Banned'] == 1)
  23. {
  24. echo "<center><font color='white'><b>".date("d/m/Y @ H:i:s A", $row['LastLogin'])." - <font color='red'><b><u>".$row['Name']."</u></b></font> was banned by <font color='#ff00ff'><b><u>".$row['Banee']."</u></b></font> for <font color='red'><b><u>".$row['BanReason']."</u></b></font><br></center></font>";
  25. }
  26. }
  27. }
  28. mysql_close($con);
  29. ?></body>
Add Comment
Please, Sign In to add comment