Fix login button on all pages

By passing PDO to the login bar so admins get their link
This commit is contained in:
Markus Wang Halvorsen 2018-02-24 17:02:00 +01:00
parent 3832d3fde0
commit 6777048dac
12 changed files with 12 additions and 12 deletions

View File

@ -66,7 +66,7 @@ if($new == 0){
<body>
<nav>
<?php echo navbar(3, 'admin'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -59,7 +59,7 @@ $events = array_values(array_filter(
<body>
<nav>
<?php echo navbar(2, 'admin'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -39,7 +39,7 @@ $users = $userManager->getAllUserData();
<body>
<nav>
<?php echo navbar(2, 'admin'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -41,7 +41,7 @@ $motd = $motdfetcher->getMOTD();
<body>
<nav>
<?php echo navbar(2, 'admin'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -61,7 +61,7 @@ if($new == 0){
<body>
<nav>
<?php echo navbar(3, 'admin'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -59,7 +59,7 @@ $projects = array_values(array_filter(
<body>
<nav>
<?php echo navbar(2, 'admin'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -27,7 +27,7 @@ $day = (isset($_GET['day']))
<body>
<nav>
<?php echo navbar(1, 'aktiviteter'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -30,7 +30,7 @@ $days_in_month = date('t', mktime(0, 0, 0, $month, 1, $year));
<body>
<nav>
<?php echo navbar(1, 'kalender'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -16,7 +16,7 @@ require_once dirname(dirname(__DIR__)) . implode(DIRECTORY_SEPARATOR, ['', 'inc'
<body>
<nav>
<?php echo navbar(1, 'kontakt'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -57,7 +57,7 @@ if (isset($_SESSION['userdata'])) { // if logged in with feide
<body>
<nav>
<?php echo navbar(1); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -57,7 +57,7 @@ if($new == 0){
<body>
<nav>
<?php echo navbar(1, 'prosjekt'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>

View File

@ -22,7 +22,7 @@ $projects = $projectManager->getAll();
<body>
<nav>
<?php echo navbar(1, 'prosjekt'); ?>
<?php echo loginbar(); ?>
<?php echo loginbar(null, $pdo); ?>
</nav>
<main>