-
Notifications
You must be signed in to change notification settings - Fork 0
/
post.php
119 lines (109 loc) · 3.94 KB
/
post.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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
<!doctype html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" integrity="sha384-JcKb8q3iqJ61gNV9KGb8thSsNjpSL0n8PARn9HuZOnIxN0hoP+VmmDGMN5t9UJ0Z" crossorigin="anonymous">
<link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css">
<title>Book share</title>
</head>
<body>
<?php include'partials/header.php';?>
<?php include'partials/dbconnect.php';?>
<?php
$p_id=$_GET['pid'];
$sql="SELECT * FROM postbook WHERE p_id=$p_id";
$result = mysqli_query($conn,$sql);
while($row=mysqli_fetch_assoc($result))
{
$bok_n=$row['b_name'];
$og_pr=$row['og_pr'];
$ex_pr=$row['ex_pr'];
$auth_n=$row['b_auth'];
$des_n=$row['descript'];
// $isbn_n=$row['b_isbn'];
$cat1=$row['genr1'];
$cat2=$row['genr2'];
$cat3=$row['genr3'];
$cat4=$row['genr4'];
$time=$row['dt_creation'];
$pic1=$row['pic1'];
$pic2=$row['pic2'];
$pic3=$row['pic3'];
$usrid=$row['usenam'];
echo '<br>
<div class="container">
<div class="jumbotron">
<h1 class="display-4"><b>'.$bok_n.'</b></h1>
<div class="w3-row-padding">
<div class="w3-col s4">
<img src="project_x_copy/'.$pic1.'" style="width:100%">
</div>
<div class="w3-col s4">
<img src="project_x_copy/'.$pic2.'" style="width:100%">
</div>
<div class="w3-col s4">
<img src="project_x_copy/'.$pic3.'" style="width:100%">
</div>
</div>
<p class="lead">
<h6> Description </h6>'.$des_n.'</p>
<hr class="my-4">
<div class="w3-row-padding">
<div class="w3-col s6">
<div class="w3-panel w3-border w3-round-xlarge">
<h6>Author: </h6> '.$auth_n.'
</div>
</div>
</div>
<!--row2-->
<div class="w3-row-padding">
<div class="w3-col s6">
<div class="w3-panel w3-border w3-round-xlarge">
<h6>Original Price: </h6> '.$og_pr.'
</div>
</div>
<div class="w3-col s6">
<div class="w3-panel w3-border w3-round-xlarge">
<h6>Expected Price: </h6> '.$ex_pr.'
</div>
</div>
</div>
<!--row3-->
<div class="w3-row-padding">
<div class="w3-col s3">
<div class="w3-panel w3-border w3-round-xlarge">
<h6>Category 1: </h6> '.$cat1.'
</div>
</div>
<div class="w3-col s3">
<div class="w3-panel w3-border w3-round-xlarge">
<h6>Category 2: </h6> '.$cat2.'
</div>
</div>
<div class="w3-col s3">
<div class="w3-panel w3-border w3-round-xlarge">
<h6>Category 3: </h6> '.$cat3.'
</div>
</div>
<div class="w3-col s3">
<div class="w3-panel w3-border w3-round-xlarge">
<h6>Category 4: </h6> '.$cat4.'
</div>
</div>
</div>
<!--end row-->
</div>
<a class="btn btn-primary btn-lg" href="#" role="button" data-toggle="modal" data-target="#buyrequestmodal">Buying Request!</a>
</div>
</div>
</div>';
}
?>
<br>
<?php include'partials/buyreq.php';?>
<?php include'partials/footer.php';?>
</body>
</html>