page: authorise user logins at page start
authorMischa POSLAWSKY <perl@shiar.org>
Tue, 11 Jul 2017 15:25:57 +0000 (17:25 +0200)
committerMischa POSLAWSKY <perl@shiar.org>
Wed, 12 Jul 2017 02:46:06 +0000 (04:46 +0200)
Move from foot to head to allow usage in all pages.

foot.inc.php
head.inc.php

index 229cae8dea3294ee46aa3fa0ecdd16fd4a06f516..e1ea486747d37aee7372df16f418fe2c4a4e1f55 100755 (executable)
@@ -3,7 +3,7 @@
 <?php
 define('N', "\n");
 
-include 'auth.inc.php';
+global $User, $editable;
 
 $curfile = ltrim($_SERVER['SCRIPT_NAME'], '/');
 if (is_executable(__DIR__ . '/' . $curfile)) {
index 847d515b3257727c02a9087cbcd159480d745621..4489ce9856875a388a6e4a7022ce2a70ba92fe6b 100644 (file)
@@ -3,6 +3,8 @@ include 'head.inc.html';
 
 print '<div class="article">'."\n\n";
 
+include_once 'auth.inc.php';
+
 register_shutdown_function(function () {
        include 'foot.inc.php';
 });