forked from Gerina-MC/Seamless
-
Notifications
You must be signed in to change notification settings - Fork 0
/
browse.php
79 lines (78 loc) · 3.92 KB
/
browse.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
<!DOCTYPE html>
<html lang="en">
<head>
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" crossorigin="anonymous">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<meta charset="utf-8">
<style>
.navbar{
background-color: #f3f3f3;
}
</style>
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" crossorigin="anonymous"></script>
<nav class="navbar navbar-expand-md navbar-light fixed-top" style="width:100%">
<div class="container-fluid navbar-left">
<a href="index.php" class="navbar-brand navbar-left">
<h2><img src="Seamlogo.svg" alt="Seamless logo" class="d-inline-block align-text-center" style="height:50px;width:50px;">
Seamless</h2>
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#collapsibleNavbar">
<span class="navbar-toggler-icon"></span>
</div>
<div class="navbar-nav" >
<div class="collapse navbar-collapse navbar-right" id="collapsibleNavbar">
<a class="nav-link" style="padding-left:10px" href="index.php">Home</a>
<a class="nav-link active" style="padding-left:10px" href="browse.php">Browse</a>
<a class="nav-link" style="padding-left:10px" href="about.php">About</a>
<?PHP
session_start();
if (!(isset($_SESSION['login']) && $_SESSION['login'] != '')) {
echo "<a class='nav-link' style='padding-left:10px' href='login.php'>Login</a>";
}
else{
echo "<a class='nav-link' style='padding-left:10px' href='design_upload.php'>Upload Design</a>";
echo "<a class='nav-link' style='padding-left:10px' href='profile.php'>Profile</a>";
echo "<a class='nav-link' style='padding-left:10px' href='logout.php'>Logout</a>";
}
?>
</div>
</div>
</nav>
<div style="height:85px"></div>
<div>
<h3 style="padding: 1rem 0 0 2rem; color:rgb(0, 0, 94)">List of designers</h3>
<div style="display:flex;flex-wrap:wrap;margin: 10px;">
<?php
error_reporting(0);
include('connection.php');
$res=mysqli_query($con,"select * from login_details");
while($row = mysqli_fetch_array($res)) {
$Username=$row['Username'];
$Name=$row['Name'];
$Mail=$row['Email_address'];
$result = mysqli_query($con, "select *from image where username = '$Username'");
$row = mysqli_fetch_array($result, MYSQLI_ASSOC);
$count = mysqli_num_rows($result);
if($count)
{
echo "<div style='display: flex; justify-content:center; width:230px; margin: 5px; padding: 2rem 1rem; border: none; border-radius: 2%; box-shadow: 5px 10px 18px #888888;'>
<div style='padding: 5px;'>
<img src='profile.jpg' alt='profile-pic' style='height: 50px; border-radius: 100%;'>
</div>
<div style='text-align: left;'>
<h4><a href='designer_details.php?user={$Username}'>{$Name}</a></h5>
<h6>Contact me:</h6>
<h6>{$Mail}</h6>
</div>
</div>" ;
}
}
?>
</div>
</div>
</body>
</html>