aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/common.php
diff options
context:
space:
mode:
authorBart van Bragt <bartvb@users.sourceforge.net>2001-02-24 10:01:48 +0000
committerBart van Bragt <bartvb@users.sourceforge.net>2001-02-24 10:01:48 +0000
commitec0dde06755d1ac80943eb858e4cb40d5b332622 (patch)
treeacb31670cbb4eb2dfb4e606340338a3f7fafdefa /phpBB/common.php
parent671510cb72f2b86bba2e0aed344945f974b90d66 (diff)
downloadforums-ec0dde06755d1ac80943eb858e4cb40d5b332622.tar
forums-ec0dde06755d1ac80943eb858e4cb40d5b332622.tar.gz
forums-ec0dde06755d1ac80943eb858e4cb40d5b332622.tar.bz2
forums-ec0dde06755d1ac80943eb858e4cb40d5b332622.tar.xz
forums-ec0dde06755d1ac80943eb858e4cb40d5b332622.zip
Changed the order of some statements
git-svn-id: file:///svn/phpbb/trunk@41 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/common.php')
-rw-r--r--phpBB/common.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/phpBB/common.php b/phpBB/common.php
index 3c33e94bf7..55e9e2da3d 100644
--- a/phpBB/common.php
+++ b/phpBB/common.php
@@ -39,18 +39,13 @@ include('functions/auth.'.$phpEx);
include('functions/functions.'.$phpEx);
include('db.'.$phpEx);
-// Check if user is banned
-if(!auth("ip ban", $db, "", "", "", "", "", USER_IP, "", "", ""))
-{
- error_die($db, BANNED);
-}
-
// Initalize these variables to keep them safe.
$user_logged_in = 0;
$logged_in = 0;
$userdata = Array();
// Setup forum wide options.
+// This is also the first DB query/connect
$sql = "SELECT * FROM ".CONFIG_TABLE." WHERE selected = 1";
if(!$result = $db->sql_query($sql))
{
@@ -74,6 +69,12 @@ else
$sys_lang = $default_lang;
}
+// Check if user is banned
+if(!auth("ip ban", $db, "", "", "", "", "", USER_IP, "", "", ""))
+{
+ error_die($db, BANNED);
+}
+
if(isset($HTTP_COOKIE_VARS[$session_cookie]))
{
$sessid = $HTTP_COOKIE_VARS[$session_cookie];