Merge branch 'lars' into 'master'

Lars

See merge request !159
This commit was merged in pull request #163.
This commit is contained in:
Lars van Hijfte
2017-01-31 16:03:05 +01:00
25 changed files with 145 additions and 64 deletions

View File

@@ -19,9 +19,12 @@
require_once ("../queries/checkInput.php");
require_once ("../queries/connect.php");
require_once ("../queries/user.php");
session_start();
if(!isset($_SESSION["userID"])){
header("location:login.php");
}
} else {
updateLastActivity();
}

View File

@@ -25,8 +25,7 @@ $userinfo = getHeaderInfo();
</div>
<?=$userinfo["fname"]?>
</div>
<img id="own-profile-picture" class="profile-picture" src="<?=$userinfo["profilepicture"]?>"/>
<i id="open-notifications" class="fa fa-bars"></i>
<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"); ?>

View File

@@ -7,9 +7,9 @@
include_once ("../queries/user.php");
// auth
$userinfo = getRoleByID($_SESSION['userID'])->fetch(PDO::FETCH_ASSOC);
$role = getRoleByID($_SESSION['userID']);
if ($userinfo['role'] == 'admin' OR $userinfo['role'] == 'owner') {
if ($role == 'admin' OR $role == 'owner') {
echo "<a href=\"admin.php\" data-title=\"Admin\"><i class=\"fa fa-lock\"></i></a>";
echo "<style>@import url('styles/adminbutton.css'); </style>";
}

View File

@@ -24,7 +24,7 @@ echo("
<div class="commentfield">
<form id="newcommentform" onsubmit="return false;">
<input type="hidden" id="newcomment-textarea" name="postID" value="<?= $postID ?>">
<textarea id="newcomment" name="newcomment-content" placeholder="Laat een reactie achter..."></textarea> <br>
<textarea id="newcomment" name="newcomment-content" placeholder="Laat een reactie achter..." maxlength="1000"></textarea><span></span> <br>
<button onclick="postComment('reaction')" name="button" value="reaction">Reageer!</button>
<button onclick="postComment('nietslecht')" name="button" value="nietslecht" class="nietslecht">
<?php

View File

@@ -1,10 +1,10 @@
<div class="content">
<div class="user-box">
<img class="profile-picture main-picture" src="<?= $user["profilepicture"] ?>"><br />
<img class="profile-picture main-picture <?= $user["onlinestatus"] ?>" src="<?= $user["profilepicture"] ?>"><br />
<div class="platform">
<div class="status-buttons-container">
<button disabled class="gray">
<?= $user["onlinestatus"] ?>
<?= $user["onlinestatus"] ?>
</button>
<button disabled class="gray"><?= $user["role"] ?></button>
</div>

View File

@@ -99,7 +99,8 @@ $settings = getSettings();
rows="5"
title="bio"
id="bio"
><?=$settings["bio"]?></textarea>
maxlength="1000"
><?=$settings["bio"]?></textarea><span></span>
</li>
<li>
<label></label>