-
Notifications
You must be signed in to change notification settings - Fork 1
/
a-home.php
198 lines (159 loc) · 3.86 KB
/
a-home.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
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
<?php
include "auth/connection.php";
session_start();
$m="";
$conn = connect();
include ('a-navbar.php');
$id= $_SESSION['userid'];
$sq= "SELECT * FROM users WHERE id='$id'";
$thisUser= mysqli_fetch_assoc($conn->query($sq));
$sql = "SELECT * FROM post ORDER BY id DESC";
$post=$conn->query($sql);
?>
<!doctype html>
<html lang="en">
<head>
<!-- Bootstrap core CSS -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3" crossorigin="anonymous">
<!-- Favicons -->
<link rel="manifest" href="https://getbootstrap.com/docs/5.1/assets/img/favicons/manifest.json">
<meta name="theme-color" content="#7952b3">
<style>
body{
margin-top:20px;
background:#fff;
}
.avatar {
position: relative;
display: inline-block;
width: 40px;
white-space: nowrap;
border-radius: 1000px;
vertical-align: bottom
}
.avatar i {
position: absolute;
right: 0;
bottom: 0;
width: 10px;
height: 10px;
border: 2px solid #fff;
border-radius: 100%
}
.avatar img {
width: 100%;
max-width: 100%;
height: auto;
border: 0 none;
border-radius: 1000px;
box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 3px 1px -2px rgba(0, 0, 0, 0.2), 0 1px 5px 0 rgba(0, 0, 0, 0.12);
}
.avatar-online i {
background-color: #4caf50
}
.avatar-off i {
background-color: #616161
}
.avatar-busy i {
background-color: #ff9800
}
.avatar-away i {
background-color: #f44336
}
.avatar-100 {
width: 100px
}
.avatar-100 i {
height: 20px;
width: 20px
}
.avatar-lg {
width: 50px
}
.avatar-lg i {
height: 12px;
width: 12px
}
.avatar-sm {
width: 30px
}
.avatar-sm i {
height: 8px;
width: 8px
}
.avatar-xs {
width: 20px
}
.avatar-xs i {
height: 7px;
width: 7px
}
.list-group-item {
position: relative;
display: block;
padding: 10px 15px;
margin-bottom: -1px;
background-color: #fff;
/* border: 1px solid transparent; */
}
</style>
</head>
<body>
<br>
<br>
<br>
<div class="container">
<div class="row">
<div class="col-md-6 col-xs-12 col-md-offset-3">
<div class="panel">
<div class="panel-heading">
<h3 class="panel-title">Posts</h3>
</div>
<div class="panel-body">
<ul class="list-group list-group-dividered list-group-full">
<li class="list-group-item">
<div class="media">
<?php
if(mysqli_num_rows($post)>0){
while($row= mysqli_fetch_assoc($post)){
echo "<div class='media-left'>";
echo " <a class='avatar avatar-online' href='javascript:void(0)'>";
echo " <img src='https://bootdey.com/img/Content/avatar/avatar1.png'>";
echo "<i></i>";
echo "</a>";
echo "</div>" ;
echo "<div class='media-body'>";
echo "<h4 class='media-heading'>".$row['author']."</h4>";
echo "<hr class='margin-bottom-10'>";
echo "<div class='container'>";
echo "<h4>";
echo $row['item'];
echo "</h4>";
echo "<h6>";
echo "Approximate Weight: ";
echo $row['weight'];
echo "</h6>";
echo "<p>";
echo $row['details'];
echo "</p>";
echo "<h6>";
echo $row['contact'];
echo "</h6>";
echo "</div>";
echo "<hr class='margin-bottom-10'>";
}
}
?>
</div>
</div>
</li>
</ul>
</div>
</div>
</div>
</div>
</div>
</body>
</html>