diff options
author | Meik Sievertsen <acydburn@phpbb.com> | 2005-04-30 14:16:21 +0000 |
---|---|---|
committer | Meik Sievertsen <acydburn@phpbb.com> | 2005-04-30 14:16:21 +0000 |
commit | 7eee98f316bc587fe7e73eaf5aa0aff3e1809ffb (patch) | |
tree | 7867c5995a5bc9965f5648e3f6b5361723b0e991 /phpBB | |
parent | 7c8ed09c9a63abef56451a681038283aec14b65b (diff) | |
download | forums-7eee98f316bc587fe7e73eaf5aa0aff3e1809ffb.tar forums-7eee98f316bc587fe7e73eaf5aa0aff3e1809ffb.tar.gz forums-7eee98f316bc587fe7e73eaf5aa0aff3e1809ffb.tar.bz2 forums-7eee98f316bc587fe7e73eaf5aa0aff3e1809ffb.tar.xz forums-7eee98f316bc587fe7e73eaf5aa0aff3e1809ffb.zip |
- topic/forum icon img additions
git-svn-id: file:///svn/phpbb/trunk@5134 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB')
-rw-r--r-- | phpBB/includes/mcp/mcp_forum.php | 28 | ||||
-rw-r--r-- | phpBB/includes/ucp/ucp_main.php | 8 | ||||
-rw-r--r-- | phpBB/includes/ucp/ucp_pm_viewfolder.php | 2 | ||||
-rw-r--r-- | phpBB/includes/ucp/ucp_zebra.php | 1 |
4 files changed, 29 insertions, 10 deletions
diff --git a/phpBB/includes/mcp/mcp_forum.php b/phpBB/includes/mcp/mcp_forum.php index 6478d02d54..56f76b5455 100644 --- a/phpBB/includes/mcp/mcp_forum.php +++ b/phpBB/includes/mcp/mcp_forum.php @@ -82,6 +82,10 @@ function mcp_forum_view($id, $mode, $action, $url, $forum_info) 'TOTAL' => $forum_topics) ); + // Grab icons + $icons = array(); + obtain_icons($icons); + $topic_rows = array(); $sql = 'SELECT t.* @@ -125,25 +129,30 @@ function mcp_forum_view($id, $mode, $action, $url, $forum_info) if ($row['topic_status'] == ITEM_LOCKED) { - $folder_img = $user->img('folder_locked', 'VIEW_TOPIC_LOCKED'); + $folder_img = 'folder_locked'; + $folder_alt = 'VIEW_TOPIC_LOCKED'; } else { if ($row['topic_type'] == POST_ANNOUNCE || $row['topic_type'] == POST_GLOBAL) { - $folder_img = $user->img('folder_announce', 'VIEW_TOPIC_ANNOUNCEMENT'); + $folder_img = 'folder_announce'; + $folder_alt = 'VIEW_TOPIC_ANNOUNCEMENT'; } else if ($row['topic_type'] == POST_STICKY) { - $folder_img = $user->img('folder_sticky', 'VIEW_TOPIC_STICKY'); + $folder_img = 'folder_sticky'; + $folder_alt = 'VIEW_TOPIC_STICKY'; } else if ($row['topic_status'] == ITEM_MOVED) { - $folder_img = $user->img('folder_moved', 'VIEW_TOPIC_MOVED'); + $folder_img = 'folder_moved'; + $folder_alt = 'VIEW_TOPIC_MOVED'; } else { - $folder_img = $user->img('folder', 'NO_NEW_POSTS'); + $folder_img = 'folder'; + $folder_alt = 'NO_NEW_POSTS'; } } @@ -179,8 +188,13 @@ function mcp_forum_view($id, $mode, $action, $url, $forum_info) 'U_MCP_QUEUE' => $url . '&i=queue&mode=approve_details&t=' . $row['topic_id'], 'U_MCP_REPORT' => "mcp.$phpEx$SID&i=main&mode=topic_view&t={$row['topic_id']}&action=reports", - 'ATTACH_ICON_IMG' => ($auth->acl_gets('f_download', 'u_download', $row['forum_id']) && $row['topic_attachment']) ? $user->img('icon_attach', sprintf($user->lang['TOTAL_ATTACHMENTS'], $row['topic_attachment'])) : '', - 'TOPIC_FOLDER_IMG' => $folder_img, + 'ATTACH_ICON_IMG' => ($auth->acl_gets('f_download', 'u_download', $row['forum_id']) && $row['topic_attachment']) ? $user->img('icon_attach', $user->lang['TOTAL_ATTACHMENTS']) : '', + 'TOPIC_FOLDER_IMG' => $user->img($folder_img, $folder_alt), + 'TOPIC_FOLDER_IMG_SRC' => $user->img($folder_img, $folder_alt, false, '', 'src'), + 'TOPIC_ICON_IMG' => (!empty($icons[$row['icon_id']])) ? $icons[$row['icon_id']]['img'] : '', + 'TOPIC_ICON_IMG_WIDTH' => (!empty($icons[$row['icon_id']])) ? $icons[$row['icon_id']]['width'] : '', + 'TOPIC_ICON_IMG_HEIGHT' => (!empty($icons[$row['icon_id']])) ? $icons[$row['icon_id']]['height'] : '', + 'TOPIC_TYPE' => $topic_type, 'TOPIC_TITLE' => $topic_title, 'REPLIES' => $row['topic_replies'], diff --git a/phpBB/includes/ucp/ucp_main.php b/phpBB/includes/ucp/ucp_main.php index 692d1a53ea..4a98ea2829 100644 --- a/phpBB/includes/ucp/ucp_main.php +++ b/phpBB/includes/ucp/ucp_main.php @@ -389,6 +389,7 @@ class ucp_main extends module $template->assign_block_vars('forumrow', array( 'FORUM_ID' => $forum_id, 'FORUM_FOLDER_IMG' => $user->img($folder_image, $folder_alt), + 'FORUM_FOLDER_IMG_SRC' => $user->img($folder_image, $folder_alt, false, '', 'src'), 'FORUM_NAME' => $row['forum_name'], 'LAST_POST_IMG' => $user->img('icon_post_latest', 'VIEW_LATEST_POST'), 'LAST_POST_TIME' => $last_post_time, @@ -487,8 +488,11 @@ class ucp_main extends module 'LAST_POST_IMG' => $user->img('icon_post_latest', 'VIEW_LATEST_POST'), 'NEWEST_POST_IMG' => $newest_post_img, 'TOPIC_FOLDER_IMG' => $user->img($folder_img, $folder_alt), - 'TOPIC_ICON_IMG' => (!empty($icons[$row['icon_id']])) ? '<img src="' . $config['icons_path'] . '/' . $icons[$row['icon_id']]['img'] . '" width="' . $icons[$row['icon_id']]['width'] . '" height="' . $icons[$row['icon_id']]['height'] . '" alt="" title="" />' : '', - 'ATTACH_ICON_IMG' => ($auth->acl_gets('f_download', 'u_download', $forum_id) && $row['topic_attachment']) ? $user->img('icon_attach', sprintf($user->lang['TOTAL_ATTACHMENTS'], $row['topic_attachment'])) : '', + 'TOPIC_FOLDER_IMG_SRC' => $user->img($folder_img, $folder_alt, false, '', 'src'), + 'TOPIC_ICON_IMG' => (!empty($icons[$row['icon_id']])) ? $icons[$row['icon_id']]['img'] : '', + 'TOPIC_ICON_IMG_WIDTH' => (!empty($icons[$row['icon_id']])) ? $icons[$row['icon_id']]['width'] : '', + 'TOPIC_ICON_IMG_HEIGHT' => (!empty($icons[$row['icon_id']])) ? $icons[$row['icon_id']]['height'] : '', + 'ATTACH_ICON_IMG' => ($auth->acl_gets('f_download', 'u_download', $forum_id) && $row['topic_attachment']) ? $user->img('icon_attach', $user->lang['TOTAL_ATTACHMENTS']) : '', 'S_TOPIC_TYPE' => $row['topic_type'], 'S_USER_POSTED' => (!empty($row['mark_type'])) ? true : false, diff --git a/phpBB/includes/ucp/ucp_pm_viewfolder.php b/phpBB/includes/ucp/ucp_pm_viewfolder.php index 89fe1d53c8..78607e81e8 100644 --- a/phpBB/includes/ucp/ucp_pm_viewfolder.php +++ b/phpBB/includes/ucp/ucp_pm_viewfolder.php @@ -156,7 +156,7 @@ function view_folder($id, $mode, $folder_id, $folder, $type) 'PM_ICON_IMG' => (!empty($icons[$row['icon_id']])) ? '<img src="' . $config['icons_path'] . '/' . $icons[$row['icon_id']]['img'] . '" width="' . $icons[$row['icon_id']]['width'] . '" height="' . $icons[$row['icon_id']]['height'] . '" alt="" title="" />' : '', 'FOLDER_IMG' => $user->img($folder_img, $folder_alt), 'PM_IMG' => ($row_indicator) ? $user->img('pm_' . $row_indicator, '') : '', - 'ATTACH_ICON_IMG' => ($auth->acl_get('u_download') && $row['message_attachment'] && $config['allow_pm_attach'] && $config['auth_download_pm']) ? $user->img('icon_attach', sprintf($user->lang['TOTAL_ATTACHMENTS'], $row['message_attachment'])) : '', + 'ATTACH_ICON_IMG' => ($auth->acl_get('u_download') && $row['message_attachment'] && $config['allow_pm_attach'] && $config['auth_download_pm']) ? $user->img('icon_attach', $user->lang['TOTAL_ATTACHMENTS']) : '', 'S_PM_REPORTED' => (!empty($row['message_reported']) && $auth->acl_get('m_')) ? true : false, 'S_PM_DELETED' => ($row['deleted']) ? true : false, diff --git a/phpBB/includes/ucp/ucp_zebra.php b/phpBB/includes/ucp/ucp_zebra.php index ae0d5b496c..496b97ece4 100644 --- a/phpBB/includes/ucp/ucp_zebra.php +++ b/phpBB/includes/ucp/ucp_zebra.php @@ -121,6 +121,7 @@ class ucp_zebra extends module break; case 'mysql4': + case 'mysqli': case 'mssql': case 'sqlite': $sql = 'INSERT INTO ' . ZEBRA_TABLE . " (user_id, zebra_id, $sql_mode) |