mirror of
				https://gitlab.com/ruany/litebans-php.git
				synced 2025-10-29 22:12:25 +00:00 
			
		
		
		
	More cleanup
This commit is contained in:
		
							parent
							
								
									647b52cf9b
								
							
						
					
					
						commit
						45dd505554
					
				
							
								
								
									
										25
									
								
								bans.php
									
									
									
									
									
								
							
							
						
						
									
										25
									
								
								bans.php
									
									
									
									
									
								
							| @ -5,7 +5,6 @@ | ||||
| <body> | ||||
| <div class="container"> | ||||
|     <div class="row"> | ||||
| 
 | ||||
|         <div class="col-lg-12"> | ||||
|             <h1 class="page-header">Bans</h1> | ||||
|             <ol class="breadcrumb"> | ||||
| @ -13,7 +12,6 @@ | ||||
|                 <li class="active">Bans</li> | ||||
|             </ol> | ||||
|         </div> | ||||
| 
 | ||||
|     </div> | ||||
|     <div class="row" style="margin-bottom:60px;"> | ||||
|         <div class="col-lg-12"> | ||||
| @ -41,24 +39,13 @@ | ||||
|                 <?php | ||||
|                 $result = run_query($table_bans); | ||||
|                 while ($row = $result->fetch_assoc()) { | ||||
|                     // <<-----------------Ban Date Converter------------>> //
 | ||||
|                     date_default_timezone_set("UTC"); | ||||
|                     $timeEpoch = $row['time']; | ||||
|                     $timeConvert = $timeEpoch / 1000; | ||||
|                     $timeResult = date('F j, Y, g:i a', $timeConvert); | ||||
|                     // <<-----------------Expiration Time Converter------------>> //
 | ||||
|                     $expiresEpoch = $row['until']; | ||||
|                     $expiresConvert = $expiresEpoch / 1000; | ||||
|                     $expiresResult = date('F j, Y, g:i a', $expiresConvert); | ||||
|                     $timeResult = date('F j, Y, g:i a', $row['time'] / 1000); | ||||
|                     $expiresResult = date('F j, Y, g:i a', $row['until'] / 1000); | ||||
|                     ?>
 | ||||
|                     <tr> | ||||
| 
 | ||||
|                         <td><?php $banned = $row['name']; | ||||
|                             echo "<img src='https://minotar.net/avatar/" . $banned . "/25' style='margin-bottom:5px;margin-right:5px;border-radius:2px;' />" . $banned; ?>
 | ||||
|                         </td> | ||||
|                         <td><?php $banner = get_banner_name($row['banned_by_name']); | ||||
|                             echo "<img src='https://minotar.net/avatar/" . $banner . "/25'  style='margin-bottom:5px;margin-right:5px;border-radius:2px;' />" . $banner ?>
 | ||||
|                         </td> | ||||
|                         <td><?php echo get_avatar($row['name']); ?> </td>
 | ||||
|                         <td><?php echo get_avatar($row['banned_by_name']); ?> </td>
 | ||||
|                         <td style="width: 30%;"><?php echo $row['reason']; ?></td>
 | ||||
|                         <td><?php echo $timeResult; ?></td>
 | ||||
|                         <td> | ||||
| @ -74,8 +61,10 @@ | ||||
|                     </tr> | ||||
|                 <?php } | ||||
|                 $result->free(); | ||||
|                 echo "</tbody></table>"; | ||||
|                 $conn->close(); | ||||
|                 ?>
 | ||||
|                 </tbody> | ||||
|             </table> | ||||
|         </div> | ||||
|     </div> | ||||
|     <?php include 'includes/footer.php'; ?>
 | ||||
|  | ||||
| @ -17,4 +17,8 @@ function run_query($table) { | ||||
|     return $result; | ||||
| } | ||||
| 
 | ||||
| function get_avatar($name) { | ||||
|     return "<img src='https://minotar.net/avatar/" . $name . "/25' style='margin-bottom:5px;margin-right:5px;border-radius:2px;' />" . $name; | ||||
| } | ||||
| 
 | ||||
| ?>
 | ||||
							
								
								
									
										21
									
								
								mutes.php
									
									
									
									
									
								
							
							
						
						
									
										21
									
								
								mutes.php
									
									
									
									
									
								
							| @ -5,7 +5,6 @@ | ||||
| <body> | ||||
| <div class="container"> | ||||
|     <div class="row"> | ||||
| 
 | ||||
|         <div class="col-lg-12"> | ||||
|             <h1 class="page-header">Mutes</h1> | ||||
|             <ol class="breadcrumb"> | ||||
| @ -13,7 +12,6 @@ | ||||
|                 <li class="active">Mutes</li> | ||||
|             </ol> | ||||
|         </div> | ||||
| 
 | ||||
|     </div> | ||||
|     <div class="row" style="margin-bottom:60px;"> | ||||
|         <div class="col-lg-12"> | ||||
| @ -31,20 +29,13 @@ | ||||
|                 <?php | ||||
|                 $result = run_query($table_mutes); | ||||
|                 while ($row = $result->fetch_assoc()) { | ||||
|                     // <<-----------------Ban Date Converter------------>> //
 | ||||
|                     date_default_timezone_set("UTC"); | ||||
|                     $timeEpoch = $row['time']; | ||||
|                     $timeConvert = $timeEpoch / 1000; | ||||
|                     $timeResult = date('F j, Y, g:i a', $timeConvert); | ||||
|                     // <<-----------------Expiration Time Converter------------>> //
 | ||||
|                     $expiresEpoch = $row['until']; | ||||
|                     $expiresConvert = $expiresEpoch / 1000; | ||||
|                     $expiresResult = date('F j, Y, g:i a', $expiresConvert); | ||||
|                     $timeResult = date('F j, Y, g:i a', $row['time'] / 1000); | ||||
|                     $expiresResult = date('F j, Y, g:i a', $row['until'] / 1000); | ||||
|                     ?>
 | ||||
|                     <tr> | ||||
|                         <td><?php echo "<img src='https://minotar.net/avatar/" . $row['name'] . "/25' style='margin-bottom:5px;margin-right:5px;border-radius:2px;' />" . $row['name']; ?></td>
 | ||||
|                         <td><?php $banner = get_banner_name($row['banned_by_name']); | ||||
|                             echo "<img src='https://minotar.net/avatar/" . $banner . "/25'  style='margin-bottom:5px;margin-right:5px;border-radius:2px;' />" . $banner; ?></td>
 | ||||
|                         <td><?php echo get_avatar($row['name']); ?> </td>
 | ||||
|                         <td><?php echo get_avatar($row['banned_by_name']); ?> </td>
 | ||||
|                         <td style="width: 30%;"><?php echo $row['reason']; ?></td>
 | ||||
|                         <td><?php echo $timeResult; ?></td>
 | ||||
|                         <td> | ||||
| @ -60,8 +51,10 @@ | ||||
|                     </tr> | ||||
|                 <?php } | ||||
|                 $result->free(); | ||||
|                 echo "</tbody></table>"; | ||||
|                 $conn->close(); | ||||
|                 ?>
 | ||||
|                 </tbody> | ||||
|             </table> | ||||
|         </div> | ||||
|     </div> | ||||
|     <?php include 'includes/footer.php'; ?>
 | ||||
|  | ||||
							
								
								
									
										16
									
								
								warnings.php
									
									
									
									
									
								
							
							
						
						
									
										16
									
								
								warnings.php
									
									
									
									
									
								
							| @ -5,7 +5,6 @@ | ||||
| <body> | ||||
| <div class="container"> | ||||
|     <div class="row"> | ||||
| 
 | ||||
|         <div class="col-lg-12"> | ||||
|             <h1 class="page-header">Warnings</h1> | ||||
|             <ol class="breadcrumb"> | ||||
| @ -13,7 +12,6 @@ | ||||
|                 <li class="active">Warnings</li> | ||||
|             </ol> | ||||
|         </div> | ||||
| 
 | ||||
|     </div> | ||||
|     <div class="row" style="margin-bottom:60px;"> | ||||
|         <div class="col-lg-12"> | ||||
| @ -38,16 +36,12 @@ | ||||
|                 <?php | ||||
|                 $result = run_query($table_warnings); | ||||
|                 while ($row = $result->fetch_assoc()) { | ||||
|                     // <<-----------------Expiration Time Converter------------>> //
 | ||||
|                     date_default_timezone_set("UTC"); | ||||
|                     $expiresEpoch = $row['until']; | ||||
|                     $expiresConvert = $expiresEpoch / 1000; | ||||
|                     $expiresResult = date('F j, Y, g:i a', $expiresConvert); | ||||
|                     $expiresResult = date('F j, Y, g:i a', $row['until'] / 1000); | ||||
|                     ?>
 | ||||
|                     <tr> | ||||
|                         <td><?php echo "<img src='https://minotar.net/avatar/" . $row['name'] . "/25' style='margin-bottom:5px;margin-right:5px;border-radius:2px;' />" . $row['name']; ?></td>
 | ||||
|                         <td><?php $banner = get_banner_name($row['banned_by_name']); | ||||
|                             echo "<img src='https://minotar.net/avatar/" . $banner . "/25'  style='margin-bottom:5px;margin-right:5px;border-radius:2px;' />" . $banner; ?></td>
 | ||||
|                         <td><?php echo get_avatar($row['name']); ?> </td>
 | ||||
|                         <td><?php echo get_avatar($row['banned_by_name']); ?> </td>
 | ||||
|                         <td style="width: 30%;"><?php echo $row['reason']; ?></td>
 | ||||
|                         <td> | ||||
|                             <?php if ($row['until'] <= 0) { | ||||
| @ -62,8 +56,10 @@ | ||||
|                     </tr> | ||||
|                 <?php } | ||||
|                 $result->free(); | ||||
|                 echo "</tbody></table>"; | ||||
|                 $conn->close(); | ||||
|                 ?>
 | ||||
|                 </tbody> | ||||
|             </table> | ||||
|         </div> | ||||
|     </div> | ||||
|     <?php include 'includes/footer.php'; ?>
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Ruan
						Ruan