aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/session.php
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2007-06-28 14:55:48 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2007-06-28 14:55:48 +0000
commitf9ea21a0836301bc21b8f1288695767cd15543ab (patch)
tree2f1c05ec6ab9300be2904e76479d0858ea8f48b8 /phpBB/includes/session.php
parentd57a16ad6964cc76843b7571f29c999ab6d8577a (diff)
downloadforums-f9ea21a0836301bc21b8f1288695767cd15543ab.tar
forums-f9ea21a0836301bc21b8f1288695767cd15543ab.tar.gz
forums-f9ea21a0836301bc21b8f1288695767cd15543ab.tar.bz2
forums-f9ea21a0836301bc21b8f1288695767cd15543ab.tar.xz
forums-f9ea21a0836301bc21b8f1288695767cd15543ab.zip
fixing some bugs
git-svn-id: file:///svn/phpbb/trunk@7805 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/session.php')
-rw-r--r--phpBB/includes/session.php13
1 files changed, 11 insertions, 2 deletions
diff --git a/phpBB/includes/session.php b/phpBB/includes/session.php
index e97f3ac8e6..35edf92749 100644
--- a/phpBB/includes/session.php
+++ b/phpBB/includes/session.php
@@ -1627,9 +1627,18 @@ class user extends session
// - add appropriate variables here, name them as they are used within the language file...
if (!$use_db)
{
- if ((include($this->lang_path . (($use_help) ? 'help_' : '') . "$lang_file.$phpEx")) === false)
+ if ($use_help && strpos($lang_file, '/') !== false)
{
- trigger_error("Language file {$this->lang_path}" . (($use_help) ? 'help_' : '') . "$lang_file.$phpEx couldn't be opened.", E_USER_ERROR);
+ $language_filename = $this->lang_path . substr($lang_file, 0, stripos($lang_file, '/') + 1) . 'help_' . substr($lang_file, stripos($lang_file, '/') + 1) . '.' . $phpEx;
+ }
+ else
+ {
+ $language_filename = $this->lang_path . (($use_help) ? 'help_' : '') . $lang_file . '.' . $phpEx;
+ }
+
+ if ((include($language_filename)) === false)
+ {
+ trigger_error("Language file $language_filename couldn't be opened.", E_USER_ERROR);
}
}
else if ($use_db)