-
Notifications
You must be signed in to change notification settings - Fork 0
/
content-bottom.php
53 lines (50 loc) · 1.48 KB
/
content-bottom.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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<?php
$query = "select distinct pro_cat from product";
$result = mysqli_query($con, $query);
echo
'<div class="content_bottom">
<div class="wrap">
<div class="content-bottom-left">
<div class="categories">
<ul>
<h3>Browse All Categories</h3>';
while($row=mysqli_fetch_array($result))
{echo '<li><a href="display.php?cat='.$row['pro_cat'].'">'.$row['pro_cat'].'</a></li>';
}
echo '</ul>
</div>
</div>
<div class="content-bottom-right">
<h3>Featured Products</h3>';
echo '<div class="section group">';
$query = "select product_name,price,product_code,image from product order by rand() limit 16";
$result = mysqli_query($con, $query);
while($row=mysqli_fetch_array($result))
{
$pro_name=$row['product_name'];
$pro_price=$row['price'];
$p_code=$row['product_code'];
echo '<div class="grid_1_of_4 images_1_of_4">
<h4><a href="preview.php?pcode='.$p_code.'">'.$pro_name.'</a></h4>
<a href="preview.php?pcode='.$p_code.'"><img src="'.$row['image'].'" alt="" style="height: 120px; width: auto";/></a>
<div class="price-details">
<div class="price-number">
<p><span class="rupees">₹'.$pro_price.'</span></p>
</div>
<div class="add-cart">
<h4><a href="preview.php?pcode='.$p_code.'">More Info</a></h4>
</div>
<div class="clear"></div>
</div>
</div>';
}
echo '</div>';
?>
<?php
echo '
</div>
<div class="clear">
</div>
</div>
</div>
' ?>