edit: distinct admin template for missing pages
[minimedit.git] / page.inc.php
index 0ca658920d98877769933d9ab9eace195de48ed8..2c1fc6c7e201f160dbc4642a8e8d1b8fc09a0dc2 100644 (file)
@@ -1,9 +1,9 @@
 <?php
-include_once 'head.inc.php';
+include_once './head.inc.php';
 
 print "<header>\n";
 ob_start();
-include 'menu.html';
+include './menu.html';
 $nav = ob_get_clean();
 $nav = preg_replace_callback('{<a href="([^"]+)">(.*?)</a>}', function ($m) {
        $request = $_SERVER['REQUEST_URI'];
@@ -13,16 +13,14 @@ $nav = preg_replace_callback('{<a href="([^"]+)">(.*?)</a>}', function ($m) {
 print $nav;
 print "</header>\n\n";
 
-print '<div class="article">'."\n\n";
-
-include_once 'auth.inc.php';
-
 register_shutdown_function(function () {
-       print "</div>\n\n";
        include 'foot.inc.php';
        print "</body></html>\n";
 });
 
-include "$Page.html";
-if (file_exists("$Page.php")) include_once("$Page.php");
+print '<div class="article">'."\n\n";
+include "./$Page.html";
+print "</div>\n\n";
+
+if (file_exists("$Page.php")) include_once("./$Page.php");