|
Server IP : 2a02:4780:11:767:0:2c41:85d9:6 / Your IP : 216.73.217.25 Web Server : LiteSpeed System : Linux in-mum-web667.main-hosting.eu 5.14.0-570.62.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Tue Nov 11 10:10:59 EST 2025 x86_64 User : u742491609 ( 742491609) PHP Version : 8.1.34 Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail MySQL : OFF | cURL : ON | WGET : ON | Perl : OFF | Python : OFF Directory (0755) : /home/u742491609/domains/../.cagefs/../.filebrowser/../public_html/admin/ |
| [ Home ] | [ C0mmand ] | [ Upload File ] |
|---|
<?php include'header.php'?>
<style>
.dt-body-nowrap {
white-space: nowrap;
}
table.dataTable.dtr-inline.collapsed>tbody>tr[role="row"]>td.no-btn:first-child:before,
table.dataTable.dtr-inline.collapsed>tbody>tr[role="row"]>th.no-btn:first-child:before
{
content: none;
}
</style>
<div class="main-content-inner">
<div class="row">
<!-- data table start -->
<div class="col-12 mt-5">
<div class="card">
<div class="card-body">
<h4 class="header-title">Blog</h4>
<div class="text-right">
<button onclick="location.href='add-blog.php'" class="btn btn-primary" type="button">Add blog</button></div>
<br><br>
<div class="data-tables">
<?php
$msql="SELECT * FROM blog";
$res = mysqli_query($con,$msql);
$count = mysqli_num_rows($res);
$i=1;
?>
<table id="dataTable" >
<thead class="bg-light text-capitalize">
<tr>
<th>SNo</th>
<th>Title</th>
<th>Image</th>
<th>Update</th>
<th>Delete</th>
</tr>
</thead>
<tbody>
<?php
while($num = mysqli_fetch_array($res))
{
$title=$num['title'];
$image=$num['image'];
?>
<tr>
<td><?php echo $i; ?></td>
<td><?php echo $title; ?></td>
<td><img src='<?php echo $image; ?>' width="100px" height="60px" ></td>
<td><a class="btn btn-success btn-sm" href="edit-blog.php?id=<?=$num['id']?>"><i class="fa fa-edit" style="font-size:20px"></i></a></td>
<td> <a onClick="return confirm('Do you want to delete title <?=$title;?> ?');" class="btn btn-danger btn-sm" href="del-blog.php?id=<?=$num['id']?>"><i class="fa fa-remove" style="font-size:20px"></i></a></td>
</tr>
<?php
$i++;
}
?>
</tbody>
</table>
</div>
</div>
</div>
</div>
<!-- data table end -->
<!-- Primary table start -->
<!-- Dark table start -->
<!-- Dark table end -->
</div>
</div>
<script>
$(document).ready(function() {
var table = $('#datatable').removeAttr('width').DataTable( {
scrollY: "20",
scrollX: true,
scrollCollapse: true,
paging: false,
columnDefs: [
{ width: 050, targets: 0 }
],
fixedColumns: true
} );
} );
</script>
<?php include'footer.php'?>