Advertisement
Guest User

changeuser

a guest
Jul 5th, 2016
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.62 KB | None | 0 0
  1. <?php include 'core/init.php';
  2. $title="Acccount Disabler";
  3. protect_page();
  4. admin_protect();
  5. include 'includes/overall/headera.php'; ?>
  6.  
  7. <h1>Account Disable System</h1>
  8.  
  9. the current time is <?php date_default_timezone_set("America/New_York"); echo date("h:i:sa");
  10. ?>
  11. <hr>
  12. <style>
  13. table {
  14. border-collapse: collapse;
  15. text-align: center;
  16. margin: 0px auto;
  17. }
  18.  
  19. table, td, th {
  20. border: 1px solid black;
  21. }
  22. </style>
  23. <?php
  24. include 'includes/admin/amenu.php';
  25. ?>
  26. <br/>
  27. <br/>
  28. <p style="font-size:16px;text-align:center;">ACCOUNT DISABLE SYSTEM V1.0<br>
  29. Please do not abuse this system any abuse of this system will automaticlly<br/> result in Account deletion and termination. <br/>
  30. <strong>for status 0 means acct is disabled 1 means acct is enabled
  31. </strong>
  32. </p>
  33. <table border="1" width="550" height="68">
  34. <tr><td width='120'>Users</td><td width='40'>Status</td><td width='50'>Rank</td><td>-</td><td width="102">Admin</td><td width="102">Moderator</td><td width="102">Builder</td></tr>
  35. <tr><td></td><td></td></tr>
  36. <?php
  37. $lquery = mysql_query("SELECT user_id, username, type, active FROM users");
  38. $lquery = mysql_query("SELECT user_id, username ,type, active FROM users WHERE active ='1'");
  39. while($run_list = mysql_fetch_array($lquery)){
  40. $id = $run_list['user_id'];
  41. $username = $run_list['username'];
  42. $type = $run_list['type'];
  43. $active = $run_list['active'];
  44. ?>
  45.  
  46. <tr><td><?php echo $username ?></td>
  47. <td><?php echo $active ?></td>
  48. <td><?php echo $type ?></td><td>
  49. <?php
  50. echo "<td>";
  51. if($type == 'admin'){
  52. echo "<a href='updateusera.php?id=&type=$type'>Revoke Admin </a>";
  53. }else{
  54. echo "<a href='updateusera.php?id=$id&type=$type'>Grant Admin </a>";
  55. }?>
  56. <?php
  57. echo "</td><td>";
  58. //============================================================================
  59. if($type == 'moderator'){
  60. echo "<a href='updateusera.php?id=$id&type=$type'>Revoke Moderator </a>";
  61. }else{
  62. echo "<a href='updateusera.php?id=$id&type=$type'>Grant Moderator </a>";
  63. }
  64. ?>
  65. <?php
  66. echo "</td><td>";
  67. //============================================================================
  68. if($type == 'builder'){
  69. echo "<a href='updateusera.php?id=$id&type=$type'>Revoke Builder</a>";
  70. }else{
  71. echo "<a href='updateusera.php?id=$id&type=$type'>Grant Builder</a>";
  72. }
  73. echo "</td>";
  74. ?>
  75. </td></tr>
  76. <?php
  77. }
  78. ?>
  79. </table>
  80. <?php include 'includes/overall/footer.php'; ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement