Ejemplo n.º 1
0
             ?>
         <tr><td colspan="4"><input style="margin-left: 5px;" type="submit" value="Update Bans" /></td></tr>
         <?php 
         }
         ?>
         </table>
         </form>
         <?php 
     }
 } elseif ($_GET['do'] == 'delete-ban') {
     ?>
     <p>On this page you can edit bans.</p>
     <?php 
     if (!empty($_GET['delete']) && is_numeric($_GET['delete'])) {
         if ($ban->checkValueExists("id", $_GET['delete'])) {
             if ($ban->deleteBan($_GET['delete'])) {
                 echo '<p class="notification green">You have successfully deleted a ban.</p>';
                 $log->addLog($_SESSION['loggedIn']['id'], "Deleted a ban.");
             }
         } else {
             echo '<p class="notification red">There was no such ban record found with this ID.</p>';
         }
     }
     ?>
     <table width="100%">
     	<tr>
         	<th width="20px">#</th>
         	<th width="150px">IP</th>
             <th>Reason</th>
             <th width="150px">When</th>
             <th width="50px">Delete</th>