Browse Source

Use footer macro

Kai Kretschmann 9 months ago
parent
commit
b0b251829c
1 changed files with 10 additions and 9 deletions
  1. 10
    9
      archived.php

+ 10
- 9
archived.php View File

@@ -4,15 +4,16 @@ require 'inc/pre.inc.php';
4 4
 define('TITLE', _('Archived'));
5 5
 require 'tpl/head.inc.php';
6 6
 
7
+define('INC_FOOTER', 'tpl/foot.inc.php');
8
+
7 9
 $l = null;
8 10
 try {
9 11
     $l = new Lggr($state, $config);
10 12
 }
11 13
 catch (LggrException $e) {
12
-    echo '<div class="container"><div class="alert alert-danger" role="alert">' .
13
-         $e->getMessage() . '</div></div>';
14
-    
15
-    require 'tpl/foot.inc.php';
14
+    echo '<div class="container"><div class="alert alert-danger" role="alert">' . $e->getMessage() . '</div></div>';
15
+
16
+    require INC_FOOTER;
16 17
     
17 18
     exit();
18 19
 }
@@ -26,10 +27,9 @@ try {
26 27
     $isSearch = false;
27 28
 }
28 29
 catch (LggrException $e) {
29
-    echo '<div class="container"><div class="alert alert-danger" role="alert">' .
30
-         $e->getMessage() . '</div></div>';
31
-    
32
-    require 'tpl/foot.inc.php';
30
+    echo '<div class="container"><div class="alert alert-danger" role="alert">' . $e->getMessage() . '</div></div>';
31
+
32
+    require INC_FOOTER;
33 33
     
34 34
     exit();
35 35
 }
@@ -145,4 +145,5 @@ if (! $isSearch) {
145 145
 
146 146
 <?php
147 147
 $aPerf = $l->getPerf();
148
-require 'tpl/foot.inc.php'?>
148
+require INC_FOOTER;
149
+?>

Loading…
Cancel
Save
Social stuff:
Mastodon