-
Notifications
You must be signed in to change notification settings - Fork 0
/
slider.new.php
34 lines (31 loc) · 968 Bytes
/
slider.new.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
<?php
$query = "select product_code, product_name,image from product order by rand() limit 12";
$result = mysqli_query($con, $query);
echo '<div class="content_top">
<div class="wrap">
<h3>Latest Products</h3>
</div>
<div class="line"> </div>
<div class="wrap">
<div class="ocarousel_slider">
<div class="ocarousel example_photos" data-ocarousel-perscroll="3">
<div class="ocarousel_window">';
while($row=mysqli_fetch_array($result))
{
$pro_name=$row['product_name'];
$p_code=$row['product_code'];
echo '<a href="preview.php?pcode='.$p_code.'" title="img1"> <img src="'.$row['image'].'" style="height:100px; width:auto;" alt="" />
<p>'.$pro_name.'</p>
</a>';
?>
<?php }
echo '</div>
<span>
<a href="#" data-ocarousel-link="left" style="float: left;" class="prev"> </a>
<a href="#" data-ocarousel-link="right" style="float: right;" class="next"> </a>
</span>
</div>
</div>
</div>
</div>
'; ?>