summaryrefslogtreecommitdiff
path: root/inc/display.php
diff options
context:
space:
mode:
authorSavetheinternet <savetheinternet@n0v4.com>2011-01-03 15:10:21 +1100
committerSavetheinternet <savetheinternet@n0v4.com>2011-01-03 15:10:21 +1100
commit083d7213f6782d33a2b5fe3de2bb767aab89e129 (patch)
treec86e4d5b22de53119186e18583f42d69a4ef52cd /inc/display.php
parent98c62258b46a40bfc1669987f227c677b9942e3d (diff)
Fixed link in "Go back" on error pages for mods
Diffstat (limited to 'inc/display.php')
-rw-r--r--inc/display.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/inc/display.php b/inc/display.php
index 028ca1aa..58f26960 100644
--- a/inc/display.php
+++ b/inc/display.php
@@ -20,7 +20,7 @@
}
function error($message) {
- global $board;
+ global $board, $mod;
if(function_exists('sql_close')) sql_close();
die(Element('page.html', Array(
@@ -29,7 +29,10 @@
'subtitle'=>'An error has occured.',
'body'=>"<center>" .
"<h2>$message</h2>" .
- (isset($board) ? "<p><a href=\"" . ROOT . $board['dir'] . FILE_INDEX . "\">Go back</a>.</p>" : '').
+ (isset($board) ?
+ "<p><a href=\"" . ROOT .
+ ($mod ? FILE_MOD . '?/' : '') .
+ $board['dir'] . FILE_INDEX . "\">Go back</a>.</p>" : '').
"</center>"
)));
}