Merge branch 'master' into hendrik-testing
This commit is contained in:
@@ -12,7 +12,6 @@ $userinfo = getHeaderInfo();
|
||||
<input name="search"
|
||||
type="text"
|
||||
placeholder="Zoek naar wat je wil"
|
||||
required
|
||||
/>
|
||||
<button type="submit">
|
||||
<i class="fa fa-search"></i>
|
||||
@@ -27,6 +26,7 @@ $userinfo = getHeaderInfo();
|
||||
<?=$userinfo["fname"]?>
|
||||
</div>
|
||||
<img id="own-profile-picture" class="profile-picture" src="<?=$userinfo["profilepicture"]?>"/>
|
||||
<i id="open-notifications" class="fa fa-bars"></i>
|
||||
</div>
|
||||
</header>
|
||||
<?php include("notification-center.php"); ?>
|
||||
|
||||
@@ -1,25 +1,33 @@
|
||||
<nav class="menu">
|
||||
<section id="friends-menu-section">
|
||||
<h4>
|
||||
Vrienden
|
||||
Top vrienden
|
||||
</h4>
|
||||
<ul id="menu-friends-list" class="nav-list">
|
||||
</ul>
|
||||
<h4><form action="search.php">
|
||||
<input type="hidden"
|
||||
value="friends"
|
||||
name="filter" />
|
||||
<button value=""
|
||||
name="search">
|
||||
Alle vrienden...
|
||||
</button>
|
||||
</form></h4>
|
||||
</section>
|
||||
<section id="groups-menu-section">
|
||||
<h4>
|
||||
Groepen
|
||||
Top groepen
|
||||
</h4>
|
||||
<ul id="menu-groups-list" class="nav-list">
|
||||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
<ul class="nav-list">
|
||||
<li>
|
||||
<form action="search.php" method="get">
|
||||
<input type="hidden"
|
||||
name="search"
|
||||
value="" />
|
||||
<input type="hidden"
|
||||
name="filter"
|
||||
value="personal" />
|
||||
<button type="submit">
|
||||
Klik voor al je groepen en vrienden...
|
||||
</button>
|
||||
</form>
|
||||
</li>
|
||||
</ul>
|
||||
</section>
|
||||
</nav>
|
||||
@@ -7,7 +7,7 @@
|
||||
</section>
|
||||
<section id="friend-request-section">
|
||||
<h4>
|
||||
Vriendchapsverzoeken
|
||||
Verzoeken
|
||||
</h4>
|
||||
<ul class="nav-list" id="friend-requests-list">
|
||||
|
||||
|
||||
@@ -21,8 +21,9 @@ echo("
|
||||
|
||||
<div class='post-comments'>
|
||||
<div class="commentfield">
|
||||
<form name="newcomment" method="post">
|
||||
<textarea placeholder="Laat een reactie achter..."></textarea> <br>
|
||||
<form id="newcommentform" action="javascript:postComment();">
|
||||
<input type="hidden" id="newcomment-textarea" name="postID" value="<?= $postID ?>">
|
||||
<textarea id="newcomment" name="newcomment-content" placeholder="Laat een reactie achter..."></textarea> <br>
|
||||
<input type="submit" value="Reageer!">
|
||||
</form>
|
||||
</div>
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<div class="friend-button-container">
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<h1 class="profile-username"><?= $user["fname"]?> <?=$user["lname"]?></h1>
|
||||
<h5 class="profile-username"><?=$user["username"]?></h5>
|
||||
<p><?=$user["bio"]?></p>
|
||||
@@ -43,37 +43,7 @@
|
||||
</div>
|
||||
|
||||
<div class="posts">
|
||||
<?php
|
||||
if ($_SESSION["userID"] === $userID) {
|
||||
?>
|
||||
<div class="post platform">
|
||||
<form>
|
||||
<input type="text" class="newpost" placeholder="Titel">
|
||||
<textarea class="newpost" placeholder="Schrijf een berichtje..."></textarea>
|
||||
<input type="submit" value="Plaats!">
|
||||
</form>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
|
||||
while($post = $posts->fetch()) {
|
||||
$nicetime = nicetime($post["creationdate"]);
|
||||
$postID = $post["postID"];
|
||||
echo "
|
||||
<div class='post platform' onclick='requestPost(this)'>
|
||||
<h2>${post["title"]}</h2>
|
||||
<p>${post["content"]}</p>
|
||||
<p class=\"subscript\" title='" . $post["creationdate"] ."'>${nicetime} geplaatst.</p>
|
||||
<form>
|
||||
<input type='hidden'
|
||||
name='postID'
|
||||
value='$postID'
|
||||
/>
|
||||
</form>
|
||||
</div>
|
||||
";
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
<div class="modal">
|
||||
|
||||
@@ -5,11 +5,11 @@ $user_perpage = $group_perpage = 20;
|
||||
$user_currentpage = $group_currentpage = 1;
|
||||
|
||||
if (isset($_GET['user-pageselect'])) {
|
||||
$user_currentpage = $_GET['user-pageselect'];
|
||||
$user_currentpage = test_input($_GET['user-pageselect']);
|
||||
}
|
||||
|
||||
if (isset($_GET['group-pageselect'])) {
|
||||
$group_currentpage = $_GET['group-pageselect'];
|
||||
$group_currentpage = test_input($_GET['group-pageselect']);
|
||||
}
|
||||
|
||||
if (isset($_GET['search'])) {
|
||||
@@ -17,7 +17,7 @@ if (isset($_GET['search'])) {
|
||||
}
|
||||
|
||||
if (isset($_GET['filter'])) {
|
||||
$filter = $_GET['filter'];
|
||||
$filter = test_input($_GET['filter']);
|
||||
}
|
||||
|
||||
$user_n = ($user_currentpage - 1) * $user_perpage;
|
||||
@@ -37,26 +37,24 @@ $group_count = countSomeGroups($search)->fetchColumn();
|
||||
Zoek:
|
||||
</label>
|
||||
<input type="text"
|
||||
id="search-input"
|
||||
name="search"
|
||||
onkeyup="
|
||||
searchUsers(<?= $user_n ?>, <?= $user_perpage ?>);
|
||||
searchGroups(<?= $group_n ?>, <?= $group_perpage ?>);"
|
||||
placeholder="Zoek"
|
||||
value=<?php echo "$search";?>
|
||||
>
|
||||
<label for="filter">
|
||||
Filter:
|
||||
</label>
|
||||
<select name="filter">
|
||||
<select name="filter" id="search-filter">
|
||||
<option value="personal"
|
||||
<?php if ($filter == "personal") echo "selected";?>>
|
||||
Persoonlijk</option>
|
||||
<option value="all"
|
||||
<?php if ($filter == "all") echo "selected";?>>
|
||||
Alles</option>
|
||||
<option value="users"
|
||||
<?php if ($filter == "users") echo "selected";?>>
|
||||
Gebruikers</option>
|
||||
<option value="groups"
|
||||
<?php if ($filter == "groups") echo "selected";?>>
|
||||
Groepen</option>
|
||||
<option value="friends"
|
||||
<?php if ($filter == "friends") echo "selected";?>>
|
||||
Vrienden</option>
|
||||
</select>
|
||||
<input onclick="document.getElementById('user-pageselect').value = 1;
|
||||
document.getElementById('group-pageselect').value = 1"
|
||||
@@ -84,31 +82,12 @@ $group_count = countSomeGroups($search)->fetchColumn();
|
||||
?>
|
||||
</select>
|
||||
|
||||
<ul class='nav-list'>
|
||||
|
||||
<?php
|
||||
$q = searchSomeUsers($user_n, $user_perpage, $search);
|
||||
|
||||
while ($user = $q->fetch(PDO::FETCH_ASSOC)) {
|
||||
$username = $user['username'];
|
||||
$profilepic = $user['profilepicture'];
|
||||
$fname = $user['fname'];
|
||||
$lname = $user['lname'];
|
||||
|
||||
echo("
|
||||
<a href='https://myhyvesbookplus.nl/profile?username=$username'>
|
||||
<li class='search-item'>
|
||||
<div class='friend'>
|
||||
<img class='profile-picture'
|
||||
src='$profilepic'>
|
||||
$fname $lname ($username)
|
||||
</div>
|
||||
</li>
|
||||
</a>
|
||||
");
|
||||
}
|
||||
?>
|
||||
|
||||
<ul id='search-users-list' class='nav-list'>
|
||||
<script>
|
||||
$(document).ready(function(){
|
||||
searchUsers(<?= $user_n ?>, <?= $user_perpage ?>);
|
||||
});
|
||||
</script>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -131,28 +110,12 @@ $group_count = countSomeGroups($search)->fetchColumn();
|
||||
?>
|
||||
</select>
|
||||
|
||||
<ul class="nav-list">
|
||||
|
||||
<?php
|
||||
$q = searchSomeGroups($group_n, $user_perpage, $search);
|
||||
|
||||
while ($group = $q->fetch(PDO::FETCH_ASSOC)) {
|
||||
$groupname = $group['name'];
|
||||
$grouppic = $group['picture'];
|
||||
|
||||
echo("
|
||||
<a href='https://myhyvesbookplus.nl/group?groupName=$groupname'>
|
||||
<li class='search-item'>
|
||||
<div class='group'>
|
||||
<img class='group-picture'
|
||||
src='$grouppic'>
|
||||
$groupname
|
||||
</div>
|
||||
</li>
|
||||
</a>
|
||||
");
|
||||
}
|
||||
?>
|
||||
<ul id="search-groups-list" class="nav-list">
|
||||
<script>
|
||||
$(document).ready(function(){
|
||||
searchGroups(<?= $group_n ?>, <?= $group_perpage ?>);
|
||||
});
|
||||
</script>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user