Added comments

Also hiding the mail/age if said so by the user
This commit is contained in:
Lars van Hijfte
2017-02-02 10:29:49 +01:00
parent 0546b8689d
commit 60b55b3f04
15 changed files with 74 additions and 15 deletions

View File

@@ -4,6 +4,7 @@ session_start();
include_once ("../../queries/friendship.php");
// Initialize variables to given or default values.
if (isset($_POST["action"])) {
$action = $_POST["action"];
} else {
@@ -18,6 +19,8 @@ if (isset($_POST["actionType"])) {
$friends = json_decode($_POST["friends"]);
// Foreach friend, return them as list item.
foreach($friends as $i => $friend) {
$friendshipStatus = getFriendshipStatus($friend->userID);
?>
@@ -48,6 +51,7 @@ foreach($friends as $i => $friend) {
</button>
</form>
<?php
// Add friendship options if possible.
if ($friendshipStatus > 1) {
if ($friendshipStatus == 2) {
$denyName = "Annuleer";

View File

@@ -6,6 +6,7 @@ include_once ("../../queries/group_member.php");
$groups = json_decode($_POST["groups"]);
// Add each group as list item.
foreach($groups as $i => $group) {
?>
<li class='group-item'>