diff options
author | Chris Smith <toonarmy@phpbb.com> | 2009-02-15 18:36:14 +0000 |
---|---|---|
committer | Chris Smith <toonarmy@phpbb.com> | 2009-02-15 18:36:14 +0000 |
commit | 07523011d2a31459ae480def55240f73248cd301 (patch) | |
tree | 8c0888765f94cbc5657a0bd516d7b110b0c24ad3 /phpBB/includes/functions_display.php | |
parent | e18d7df6c047970cb95136a0e373e80dee3b7492 (diff) | |
download | forums-07523011d2a31459ae480def55240f73248cd301.tar forums-07523011d2a31459ae480def55240f73248cd301.tar.gz forums-07523011d2a31459ae480def55240f73248cd301.tar.bz2 forums-07523011d2a31459ae480def55240f73248cd301.tar.xz forums-07523011d2a31459ae480def55240f73248cd301.zip |
Allow translation of Custom BBCode help messages.
git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9328 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/functions_display.php')
-rw-r--r-- | phpBB/includes/functions_display.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/phpBB/includes/functions_display.php b/phpBB/includes/functions_display.php index 14ab079202..a09434234e 100644 --- a/phpBB/includes/functions_display.php +++ b/phpBB/includes/functions_display.php @@ -846,7 +846,7 @@ function topic_status(&$topic_row, $replies, $unread_topic, &$folder_img, &$fold */ function display_custom_bbcodes() { - global $db, $template; + global $db, $template, $user; // Start counting from 22 for the bbcode ids (every bbcode takes two ids - opening/closing) $num_predefined_bbcodes = 22; @@ -860,6 +860,12 @@ function display_custom_bbcodes() $i = 0; while ($row = $db->sql_fetchrow($result)) { + // If the helpline is defined within the language file, we will use the localized version, else just use the database entry... + if (isset($user->lang[strtoupper($row['bbcode_helpline'])])) + { + $row['bbcode_helpline'] = $user->lang[strtoupper($row['bbcode_helpline'])]; + } + $template->assign_block_vars('custom_tags', array( 'BBCODE_NAME' => "'[{$row['bbcode_tag']}]', '[/" . str_replace('=', '', $row['bbcode_tag']) . "]'", 'BBCODE_ID' => $num_predefined_bbcodes + ($i * 2), |