aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/functions
diff options
context:
space:
mode:
authorJames Atkinson <thefinn@users.sourceforge.net>2001-02-23 20:34:43 +0000
committerJames Atkinson <thefinn@users.sourceforge.net>2001-02-23 20:34:43 +0000
commit52544a73858205d7aad76d5ca61390a2d4fbd809 (patch)
treedfbb514642f7f11029e6041528cdfb405ca65d66 /phpBB/functions
parentfb2ae00b71a57b4e9adcfb82fbb4ce9c04c2f1d8 (diff)
downloadforums-52544a73858205d7aad76d5ca61390a2d4fbd809.tar
forums-52544a73858205d7aad76d5ca61390a2d4fbd809.tar.gz
forums-52544a73858205d7aad76d5ca61390a2d4fbd809.tar.bz2
forums-52544a73858205d7aad76d5ca61390a2d4fbd809.tar.xz
forums-52544a73858205d7aad76d5ca61390a2d4fbd809.zip
View forum page is started. Need private forum checking
git-svn-id: file:///svn/phpbb/trunk@34 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/functions')
-rw-r--r--phpBB/functions/error.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/phpBB/functions/error.php b/phpBB/functions/error.php
index e4277883a2..6b53da1838 100644
--- a/phpBB/functions/error.php
+++ b/phpBB/functions/error.php
@@ -24,6 +24,7 @@
function error_die($db, $error_code = "", $error_msg = "")
{
+ global $template, $phpEx;
if(!$error_msg)
{
switch($error_code)
@@ -42,10 +43,15 @@ function error_die($db, $error_code = "", $error_msg = "")
case SESSION_CREATE:
$error_msg = "Error creating session. Could not log you in. Please go back and try again.";
break;
+ case NO_POSTS:
+ $error_msg = "There are no posts in this forum. Click on the 'Post New Topic' link on this page to post one.";
}
}
-
- die($error_msg);
+ $template->set_file(array("error_body" => "error_body.tpl"));
+ $template->set_var(array("ERROR_MESSAGE" => $error_msg));
+ $template->pparse("output", "error_body");
+ include('page_tail.'.$phpEx);
+ exit();
}