-
Notifications
You must be signed in to change notification settings - Fork 0
/
all-users.php
executable file
·37 lines (37 loc) · 3.06 KB
/
all-users.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
<?php include 'components/authentication.php' ?>
<?php include 'components/session-check.php' ?>
<?php include 'controllers/base/head.php' ?>
<?php include 'controllers/navigation/first-navigation.php' ?>
<div class="container">
<div class="row clearfix">
<div class="col-md-12 column">
<div class="row clearfix">
<?php
include '_database/database.php';
session_start();
$current_user = $_SESSION['user_username'];
$sql = "SELECT * FROM user WHERE user_username != '$current_user' order by user_id desc";
$result = mysqli_query($database,$sql) or die(mysqli_error($database));
while($rws = mysqli_fetch_array($result)){
?>
<div class="col-md-4 column">
<div class="panel-group" id="panel-<?php echo $rws['user_id']; ?>">
<div class="panel panel-default">
<div id="panel-element-<?php echo $rws['user_id']; ?>" class="panel-collapse collapse in">
<div class="panel-body">
<div class="col-md-6 column">
<img src="userfiles/avatars/<?php echo $rws['user_avatar'];?>" name="aboutme" class="img-responsive">
</div>
<div class="col-md-6 column">
<h2><span><a href="profile.php?user_username=<?php echo $rws['user_username'];?>"><?php echo $rws['user_firstname'];?> <?php echo $rws['user_lastname'];?></a></span></h2>
</div>
</div>
</div>
</div>
</div>
</div>
<?php } ?>
</div>
</div>
</div>
</div>