Made some small changes for Lars.

This commit is contained in:
K. Nobel
2017-01-24 15:01:55 +01:00
parent 4b3d7967fb
commit 4967ab6ea0
2 changed files with 13 additions and 2 deletions

View File

@@ -35,7 +35,18 @@ function getUsername($userID) {
function selectUser($me, $other) { function selectUser($me, $other) {
$stmt = $GLOBALS["db"]->prepare(" $stmt = $GLOBALS["db"]->prepare("
SELECT SELECT
`username`, `birthdate`, `location`, `profilepicture`, `bio`, `user`.`creationdate`, `onlinestatus`, `fname`, `lname`, `username`,
`birthdate`,
`location`,
IFNULL(
`profilepicture`,
'../img/avatar-standard.png'
) AS profilepicture,
`bio`,
`user`.`creationdate`,
`onlinestatus`,
`fname`,
`lname`,
CASE `status` IS NULL CASE `status` IS NULL
WHEN TRUE THEN 0 WHEN TRUE THEN 0
WHEN FALSE THEN WHEN FALSE THEN

View File

@@ -27,7 +27,7 @@
<p> <p>
<?php <?php
while($friend = $profile_friends->fetch()) { while($friend = $profile_friends->fetch()) {
echo "<a href='profile.php?username=${friend["username"]}/' data-title='${friend["username"]}'><img class='profile-picture' src='${friend["profilepicture"]}' alt='${friend["username"]}'s profielfoto></a>"; echo "<a href='profile.php?username=${friend["username"]}' data-title='${friend["username"]}'><img class='profile-picture' src='${friend["profilepicture"]}' alt='${friend["username"]}'s profielfoto></a>";
} }