-
Notifications
You must be signed in to change notification settings - Fork 0
/
homepage.php
53 lines (46 loc) · 2.19 KB
/
homepage.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
include 'headerlinks.php';
include 'template.php';
include 'sidebartemplate.php';
?>
<body>
<div class="container" id="content">
<?php
$query="SELECT * from `books` ORDER BY RAND() LIMIT 0,9 ";
$query_run=mysqli_query($link,$query);
//$row=mysqli_num_rows($query_run);
while($result=mysqli_fetch_assoc($query_run))
{
?>
<div class="col-sm-4 col-md-4">
<div class="product-image-wrapper">
<div class="panel panel-warning">
<div class="panel-heading"><i>Category : <b><?php echo $result['category'];?></b></i></div>
<div class="single-products">
<div class="productinfo text-center">
<div class="panel-body">
<img src="<?php echo $result['image'];?>" class="img responsive" />
<h2><?php echo $result['borrowal price'];?></h2><h4><del><?php echo $result['price']; ?></del></h4>
<p><h2><?php echo $result['name'].'<span class="badge">'.$result['quantity'].'</span>'; ?></h2>by <?php echo $result['author']?></p>
<button type="button" id='<?php echo $result['id'];?>' class="btn btn-warning add_to_cart"><i class="fa fa-shopping-cart"></i> Add to cart</button>
<!-- <input type="button" id= name="add_to_cart" class="btn btn-warning add_to_cart" value="add to cart"></input>-->
<!-- <a href="#" class="btn btn-default add-to-cart"><i class="fa fa-shopping-cart"></i>Add to cart</a>-->
</div>
</div>
</div>
<div class="choose">
<ul class="nav nav-pills nav-justified">
<li><a href=""><i class="fa fa-plus-square"></i>Add to wishlist</a></li>
</ul>
</div>
</div>
</div>
</div>
<?php
}
?>
<span id="nitz"></span>
<link rel="stylesheet" href="style.css" type="text/css">
<script type="text/javascript" src="js/jquery.js"></script>
<script type="text/javascript" src="js/init.js"></script>
</body>