aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions_posting.php
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2003-02-26 19:53:10 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2003-02-26 19:53:10 +0000
commit541667f440b245535354febd18930a87c2bbbefb (patch)
tree154386a019e66e8fd89b5ac0dd218fa11e7e3d88 /phpBB/includes/functions_posting.php
parentc3200c107f1e5b297d3c351e7ce0b8aee61a7dc7 (diff)
downloadforums-541667f440b245535354febd18930a87c2bbbefb.tar
forums-541667f440b245535354febd18930a87c2bbbefb.tar.gz
forums-541667f440b245535354febd18930a87c2bbbefb.tar.bz2
forums-541667f440b245535354febd18930a87c2bbbefb.tar.xz
forums-541667f440b245535354febd18930a87c2bbbefb.zip
some changes... mainly permission related. Please note the intval($forum_id) at viewtopic, somehow the auth class did not identified it while generating the forum rules.
git-svn-id: file:///svn/phpbb/trunk@3553 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/functions_posting.php')
-rw-r--r--phpBB/includes/functions_posting.php39
1 files changed, 39 insertions, 0 deletions
diff --git a/phpBB/includes/functions_posting.php b/phpBB/includes/functions_posting.php
index 4d62320c09..f9e59efefb 100644
--- a/phpBB/includes/functions_posting.php
+++ b/phpBB/includes/functions_posting.php
@@ -507,4 +507,43 @@ function generate_smilies($mode)
}
}
+// Generate Topic Icons
+function generate_topic_icons($mode, $enable_icons)
+{
+ global $template, $config;
+
+ if (!$enable_icons)
+ {
+ return (false);
+ }
+
+ $result = false;
+
+ // Grab icons
+ $icons = array();
+ obtain_icons($icons);
+
+ if (sizeof($icons))
+ {
+ $result = true;
+
+ foreach ($icons as $id => $data)
+ {
+ if ($data['display'])
+ {
+ $template->assign_block_vars('topic_icon', array(
+ 'ICON_ID' => $id,
+ 'ICON_IMG' => $phpbb_root_path . $config['icons_path'] . '/' . $data['img'],
+ 'ICON_WIDTH' => $data['width'],
+ 'ICON_HEIGHT' => $data['height'],
+
+ 'S_ICON_CHECKED' => ($id == $icon_id && $mode != 'reply') ? ' checked="checked"' : '')
+ );
+ }
+ }
+ }
+
+ return ($result);
+}
+
?> \ No newline at end of file