-
Notifications
You must be signed in to change notification settings - Fork 0
/
categories.php
37 lines (32 loc) · 874 Bytes
/
categories.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php
include "layout/navbar.php"
?>
<div class="main">
<h3 class="heading">Explore categories</h3>
<div class="container">
<?php
$sql="select * from category where active='yes'" ;
$res=mysqli_query($conn,$sql);
// echo $res->num_rows;
while($row=$res->fetch_assoc()){
$id=$row['id'];
$title=$row['title'];
$image_name=$row['image_name'];
?>
<div class="card">
<img src="<?php echo $image_name ?>" >
<div class="details">
<h3><?php echo $title?></h3>
<div class="social-links">
<a href="category-post.php?id=<?php echo $id?>" >Explore</a>
</div>
</div>
</div>
<?php
}
?>
</div>
</div>
<?php
include "layout/footer.php"
?>