aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/includes')
-rw-r--r--phpBB/includes/acp/acp_icons.php7
-rw-r--r--phpBB/includes/functions_display.php10
2 files changed, 13 insertions, 4 deletions
diff --git a/phpBB/includes/acp/acp_icons.php b/phpBB/includes/acp/acp_icons.php
index 3ca135847d..35b41f0ae1 100644
--- a/phpBB/includes/acp/acp_icons.php
+++ b/phpBB/includes/acp/acp_icons.php
@@ -447,7 +447,6 @@ class acp_icons
'L_TITLE' => $user->lang['ACP_' . $lang],
'L_EXPLAIN' => $user->lang['ACP_' . $lang . '_EXPLAIN'],
- 'L_IMPORT' => $user->lang[$lang . '_IMPORT'],
'L_NO_PAK_OPTIONS' => $user->lang['NO_' . $lang . '_PAK'],
'L_CURRENT' => $user->lang['CURRENT_' . $lang],
'L_CURRENT_EXPLAIN' => $user->lang['CURRENT_' . $lang . '_EXPLAIN'],
@@ -547,7 +546,7 @@ class acp_icons
case 'move_up':
case 'move_down':
- $image_order = intval($_GET['order']);
+ $image_order = request_var('order', 0);
$order_total = $image_order * 2 + (($action == 'move_up') ? -1 : 1);
$sql = 'UPDATE ' . $table . '
@@ -564,7 +563,7 @@ class acp_icons
// By default, check that image_order is valid and fix it if necessary
$sql = "SELECT {$fields}_id AS order_id, {$fields}_order AS fields_order
FROM $table
- ORDER BY {$fields}_order";
+ ORDER BY display_on_posting DESC, {$fields}_order";
$result = $db->sql_query($sql);
if ($row = $db->sql_fetchrow($result))
@@ -608,7 +607,7 @@ class acp_icons
$sql = "SELECT *
FROM $table
- ORDER BY display_on_posting DESC, {$fields}_order ASC";
+ ORDER BY {$fields}_order ASC";
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result))
diff --git a/phpBB/includes/functions_display.php b/phpBB/includes/functions_display.php
index 9e38d39296..5f4f8ed5f6 100644
--- a/phpBB/includes/functions_display.php
+++ b/phpBB/includes/functions_display.php
@@ -127,6 +127,16 @@ function display_forums($root_data = '', $display_moderators = true, $return_mod
// Display active topics from this forum?
if ($show_active && $row['forum_type'] == FORUM_POST && $auth->acl_get('f_read', $forum_id) && ($row['forum_flags'] & 16))
{
+ if (!isset($active_forum_ary['forum_topics']))
+ {
+ $active_forum_ary['forum_topics'] = 0;
+ }
+
+ if (!isset($active_forum_ary['forum_posts']))
+ {
+ $active_forum_ary['forum_posts'] = 0;
+ }
+
$active_forum_ary['forum_id'][] = $forum_id;
$active_forum_ary['enable_icons'][] = $row['enable_icons'];
$active_forum_ary['forum_topics'] += ($auth->acl_get('m_approve', $forum_id)) ? $row['forum_topics_real'] : $row['forum_topics'];