-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlogged.php
More file actions
50 lines (42 loc) · 1.39 KB
/
logged.php
File metadata and controls
50 lines (42 loc) · 1.39 KB
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
<?php
$user_to_follow=$user_identity;
$selectallusersprofile=mysqli_query($con,"SELECT * FROM profile where profile.user_id='$user_identity'");
if ($selectallusersprofile) {
if (mysqli_num_rows($selectallusersprofile)>0) {
$fetchalluserprofile=mysqli_fetch_array($selectallusersprofile);
$cover="images/".$fetchalluserprofile['profile'];
}else{
$cover="images/Capture.PNG";
}
}?>
<style type="text/css">
.profileusercomment{
background: url('<?php echo($cover)?>');
background-repeat: no-repeat;
background-size: cover;
padding: 0;
width: 30px;
height: 30px;
border-radius: 50%;
}
.profileusercomment img{
border-radius: 50%;
width: 100%;
height: 100%;
}
</style>
<?php
$selectallusers=mysqli_query($con,"SELECT * FROM users where users.unique_id='$user_identity'");
if ($selectallusers) {
if (mysqli_num_rows($selectallusers)>0) {
$fetchalluser=mysqli_fetch_array($selectallusers);
$selectalluserspost=mysqli_query($con,"SELECT count(post_unique_id) as total FROM posts where posts.user_unique_id='$user_identity'");
$fetchalluserpost=mysqli_fetch_array($selectalluserspost);
$new=$fetchalluser['username'];
?>
<div class="profileusercomment">
<a href="user.php?unique_id_profile=<?php echo($username)?>"><img src="<?php echo$cover?>" class="img-thumbnail"></a>
</div>
<?php }}else{
echo $con->error;
}?>