aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--phpBB/adm/style/colour_swatch.html76
-rw-r--r--phpBB/adm/swatch.php115
-rw-r--r--phpBB/cron.php9
-rw-r--r--phpBB/includes/acp/acp_groups.php2
-rw-r--r--phpBB/includes/functions.php5
-rw-r--r--phpBB/includes/functions_module.php4
-rw-r--r--phpBB/includes/functions_privmsgs.php146
-rw-r--r--phpBB/includes/ucp/ucp_attachments.php1
-rw-r--r--phpBB/includes/ucp/ucp_groups.php3
-rw-r--r--phpBB/includes/ucp/ucp_main.php3
-rw-r--r--phpBB/includes/ucp/ucp_pm.php5
-rw-r--r--phpBB/includes/ucp/ucp_pm_options.php3
-rw-r--r--phpBB/includes/ucp/ucp_prefs.php1
-rw-r--r--phpBB/includes/ucp/ucp_profile.php1
-rw-r--r--phpBB/includes/ucp/ucp_register.php1
-rw-r--r--phpBB/includes/ucp/ucp_remind.php1
-rw-r--r--phpBB/includes/ucp/ucp_resend.php1
-rw-r--r--phpBB/includes/ucp/ucp_zebra.php1
-rw-r--r--phpBB/language/en/common.php1
-rw-r--r--phpBB/language/en/ucp.php2
-rw-r--r--phpBB/mcp.php4
-rwxr-xr-xphpBB/ucp.php14
22 files changed, 263 insertions, 136 deletions
diff --git a/phpBB/adm/style/colour_swatch.html b/phpBB/adm/style/colour_swatch.html
new file mode 100644
index 0000000000..19fa008d00
--- /dev/null
+++ b/phpBB/adm/style/colour_swatch.html
@@ -0,0 +1,76 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" dir="ltr">
+<head>
+<meta http-equiv="Content-Style-Type" content="text/css" />
+<meta http-equiv="imagetoolbar" content="no" />
+<title>{L_COLOUR_SWATCH}</title>
+
+<style type="text/css">
+<!--
+ body {
+ background-color: #404040;
+ color: #fff;
+ }
+
+ td {
+ border: solid 1px #333;
+ }
+
+ .over {
+ border-color: white;
+ }
+
+ .out {
+ border-color: #333333;
+ }
+
+ img {
+ border: 0;
+ }
+//-->
+</style>
+</head>
+
+<body>
+
+<script type="text/javascript">
+<!--
+ var r = 0, g = 0, b = 0;
+
+ var numberList = new Array(6);
+ numberList[0] = '00';
+ numberList[1] = '33';
+ numberList[2] = '66';
+ numberList[3] = '99';
+ numberList[4] = 'CC';
+ numberList[5] = 'FF';
+
+ document.writeln('<table cellspacing="0" cellpadding="0" border="0">');
+
+ for (r = 0; r < 6; r++)
+ {
+ document.writeln('<tr>');
+
+ for (g = 0; g < 6; g++)
+ {
+ for (b = 0; b < 6; b++)
+ {
+ color = String(numberList[r]) + String(numberList[g]) + String(numberList[b]);
+ document.write('<td style="background-color: #' + color + ';" onmouseover="this.className=\'over\'" onmouseout="this.className=\'out\'">');
+ document.write('<a href="javascript:cell(\'' + color + '\');"><img src="{T_IMAGES_PATH}spacer.gif" width="15" height="12" alt="#' + color + '" title="#' + color + '" \/><\/a>');
+ document.writeln('<\/td>');
+ }
+ }
+ document.writeln('<\/tr>');
+ }
+ document.writeln('<\/table>');
+
+ function cell(color)
+ {
+ opener.document.forms["{OPENER}"].{NAME}.value = color;
+ }
+//-->
+</script>
+
+</body>
+</html> \ No newline at end of file
diff --git a/phpBB/adm/swatch.php b/phpBB/adm/swatch.php
index ee3a5455c5..1051523a70 100644
--- a/phpBB/adm/swatch.php
+++ b/phpBB/adm/swatch.php
@@ -1,73 +1,48 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" dir="ltr">
-<head>
-<meta http-equiv="Content-Style-Type" content="text/css" />
-<meta http-equiv="imagetoolbar" content="no" />
-<title>Color Swatch</title>
-
-<style type="text/css">
-<!--
-body {
- background-color: #404040;
- color: #fff;
-}
-
-td {
- border: solid 1px #333;
-}
-
-.over {
- border-color: white;
-}
-
-.out {
- border-color: #333333;
-}
-
-img {
- border: 0;
-}
-
-//-->
-</style>
-</head>
-
-<body>
-
-<script type="text/javascript">
-<!--
- var r = 0, g = 0, b = 0;
- var numberList = new Array(6);
- numberList[0] = "00";
- numberList[1] = "33";
- numberList[2] = "66";
- numberList[3] = "99";
- numberList[4] = "CC";
- numberList[5] = "FF";
- document.writeln('<table cellspacing="0" cellpadding="0" border="0">');
- for(r = 0; r < 6; r++)
- {
- document.writeln('<tr>');
- for(g = 0; g < 6; g++)
- {
- for(b = 0; b < 6; b++)
- {
- color = String(numberList[r]) + String(numberList[g]) + String(numberList[b]);
- document.write('<td bgcolor="#' + color + '" onmouseover="this.className=\'over\'" onmouseout="this.className=\'out\'">');
- document.write('<a href="javascript:cell(\'' + color + '\');"><img src="./images/spacer.gif" width="15" height="12" alt="#' + color + '" title="#' + color + '" \/><\/a>');
- document.writeln('<\/td>');
- }
- }
- document.writeln('<\/tr>');
- }
- document.writeln('<\/table>');
-
-function cell(color)
+<?php
+/**
+*
+* @package phpBB3
+* @version $Id$
+* @copyright (c) 2005 phpBB Group
+* @license http://opensource.org/licenses/gpl-license.php GNU Public License
+*
+*/
+
+/**
+* @ignore
+*/
+define('IN_PHPBB', true);
+$phpbb_root_path = './../';
+$phpEx = substr(strrchr(__FILE__, '.'), 1);
+include($phpbb_root_path . 'common.' . $phpEx);
+
+// Start session management
+$user->session_begin(false);
+$auth->acl($user->data);
+$user->setup();
+
+// Set custom template for admin area
+$template->set_custom_template($phpbb_root_path . 'adm/style', 'admin');
+
+$template->set_filenames(array(
+ 'body' => 'colour_swatch.html')
+);
+
+$template->assign_vars(array(
+ 'OPENER' => addslashes(request_var('form', '')),
+ 'NAME' => request_var('name', ''),
+ 'T_IMAGES_PATH' => "{$phpbb_root_path}images/",)
+);
+
+$template->display('body');
+
+// Unload cache, must be done before the DB connection if closed
+if (!empty($cache))
{
- opener.document.forms['<?php echo htmlspecialchars(addslashes($_GET['form'])); ?>'].<?php echo htmlspecialchars(addslashes($_GET['name'])); ?>.value = color;
+ $cache->unload();
}
-//-->
-</script>
-</body>
-</html> \ No newline at end of file
+// Close our DB connection.
+$db->sql_close();
+
+?> \ No newline at end of file
diff --git a/phpBB/cron.php b/phpBB/cron.php
index 7fe4ae7da6..9f2c59966c 100644
--- a/phpBB/cron.php
+++ b/phpBB/cron.php
@@ -207,6 +207,15 @@ switch ($cron_type)
break;
}
+// Unload cache, must be done before the DB connection is closed
+if (!empty($cache))
+{
+ $cache->unload();
+}
+
+// Close our DB connection.
+$db->sql_close();
+
// Output transparent gif
header('Cache-Control: no-cache');
header('Content-type: image/gif');
diff --git a/phpBB/includes/acp/acp_groups.php b/phpBB/includes/acp/acp_groups.php
index a216a4d24f..d0560bae13 100644
--- a/phpBB/includes/acp/acp_groups.php
+++ b/phpBB/includes/acp/acp_groups.php
@@ -384,6 +384,8 @@ class acp_groups
$auth->acl_clear_prefetch();
}
+ $cache->destroy('sql', GROUPS_TABLE);
+
$message = ($action == 'edit') ? 'GROUP_UPDATED' : 'GROUP_CREATED';
trigger_error($user->lang[$message] . adm_back_link($this->u_action));
}
diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php
index 479acc291e..d6cd9efd1f 100644
--- a/phpBB/includes/functions.php
+++ b/phpBB/includes/functions.php
@@ -2343,7 +2343,7 @@ function msg_handler($errno, $msg_text, $errfile, $errline)
/**
* Generate page header
*/
-function page_header($page_title = '')
+function page_header($page_title = '', $display_online_list = true)
{
global $db, $config, $template, $SID, $_SID, $user, $auth, $phpEx, $phpbb_root_path;
@@ -2381,7 +2381,7 @@ function page_header($page_title = '')
// Get users online list ... if required
$l_online_users = $online_userlist = $l_online_record = '';
- if ($config['load_online'] && $config['load_online_time'])
+ if ($config['load_online'] && $config['load_online_time'] && $display_online_list)
{
$userlist_ary = $userlist_visible = array();
$logged_visible_online = $logged_hidden_online = $guests_online = $prev_user_id = 0;
@@ -2635,6 +2635,7 @@ function page_header($page_title = '')
'T_TEMPLATE_PATH' => "{$phpbb_root_path}styles/" . $user->theme['template_path'] . '/template',
'T_IMAGESET_PATH' => "{$phpbb_root_path}styles/" . $user->theme['imageset_path'] . '/imageset',
'T_IMAGESET_LANG_PATH' => "{$phpbb_root_path}styles/" . $user->theme['imageset_path'] . '/imageset/' . $user->data['user_lang'],
+ 'T_IMAGES_PATH' => "{$phpbb_root_path}images/",
'T_SMILIES_PATH' => "{$phpbb_root_path}{$config['smilies_path']}/",
'T_AVATAR_PATH' => "{$phpbb_root_path}{$config['avatar_path']}/",
'T_AVATAR_GALLERY_PATH' => "{$phpbb_root_path}{$config['avatar_gallery_path']}/",
diff --git a/phpBB/includes/functions_module.php b/phpBB/includes/functions_module.php
index 6f45db1538..0452be7067 100644
--- a/phpBB/includes/functions_module.php
+++ b/phpBB/includes/functions_module.php
@@ -600,7 +600,7 @@ class p_master
/**
* Display module
*/
- function display($page_title)
+ function display($page_title, $display_online_list = true)
{
global $template, $user;
@@ -611,7 +611,7 @@ class p_master
}
else
{
- page_header($page_title);
+ page_header($page_title, $display_online_list);
}
$template->set_filenames(array(
diff --git a/phpBB/includes/functions_privmsgs.php b/phpBB/includes/functions_privmsgs.php
index 8cb34bafb9..319e8810b6 100644
--- a/phpBB/includes/functions_privmsgs.php
+++ b/phpBB/includes/functions_privmsgs.php
@@ -62,7 +62,8 @@ $global_privmsgs_rules = array(
RULE_IS => array('check0' => 'message_subject', 'function' => '{CHECK0} == {STRING}'),
RULE_IS_NOT => array('check0' => 'message_subject', 'function' => '{CHECK0} != {STRING}'),
RULE_BEGINS_WITH => array('check0' => 'message_subject', 'function' => 'preg_match("/^" . preg_quote({STRING}, "/") . "/i", {CHECK0})'),
- RULE_ENDS_WITH => array('check0' => 'message_subject', 'function' => 'preg_match("/" . preg_quote({STRING}, "/") . "$/i", {CHECK0})')),
+ RULE_ENDS_WITH => array('check0' => 'message_subject', 'function' => 'preg_match("/" . preg_quote({STRING}, "/") . "$/i", {CHECK0})'),
+ ),
CHECK_SENDER => array(
RULE_IS_LIKE => array('check0' => 'username', 'function' => 'preg_match("/" . preg_quote({STRING}, "/") . "/i", {CHECK0})'),
@@ -74,21 +75,25 @@ $global_privmsgs_rules = array(
RULE_IS_FRIEND => array('check0' => 'friend', 'function' => '{CHECK0} == 1'),
RULE_IS_FOE => array('check0' => 'foe', 'function' => '{CHECK0} == 1'),
RULE_IS_USER => array('check0' => 'author_id', 'function' => '{CHECK0} == {USER_ID}'),
- RULE_IS_GROUP => array('check0' => 'author_in_group', 'function' => 'in_array({GROUP_ID}, {CHECK0})')),
+ RULE_IS_GROUP => array('check0' => 'author_in_group', 'function' => 'in_array({GROUP_ID}, {CHECK0})'),
+ ),
CHECK_MESSAGE => array(
RULE_IS_LIKE => array('check0' => 'message_text', 'function' => 'preg_match("/" . preg_quote({STRING}, "/") . "/i", {CHECK0})'),
RULE_IS_NOT_LIKE => array('check0' => 'message_text', 'function' => '!(preg_match("/" . preg_quote({STRING}, "/") . "/i", {CHECK0}))'),
RULE_IS => array('check0' => 'message_text', 'function' => '{CHECK0} == {STRING}'),
- RULE_IS_NOT => array('check0' => 'message_text', 'function' => '{CHECK0} != {STRING}')),
+ RULE_IS_NOT => array('check0' => 'message_text', 'function' => '{CHECK0} != {STRING}'),
+ ),
CHECK_STATUS => array(
RULE_ANSWERED => array('check0' => 'replied', 'function' => '{CHECK0} == 1'),
- RULE_FORWARDED => array('check0' => 'forwarded', 'function' => '{CHECK0} == 1')),
+ RULE_FORWARDED => array('check0' => 'forwarded', 'function' => '{CHECK0} == 1'),
+ ),
CHECK_TO => array(
RULE_TO_GROUP => array('check0' => 'to', 'check1' => 'bcc', 'check2' => 'user_in_group', 'function' => 'in_array("g_" . {CHECK2}, {CHECK0}) || in_array("g_" . {CHECK2}, {CHECK1})'),
- RULE_TO_ME => array('check0' => 'to', 'check1' => 'bcc', 'function' => 'in_array("u_" . $user_id, {CHECK0}) || in_array("u_" . $user_id, {CHECK1})'))
+ RULE_TO_ME => array('check0' => 'to', 'check1' => 'bcc', 'function' => 'in_array("u_" . $user_id, {CHECK0}) || in_array("u_" . $user_id, {CHECK1})'),
+ )
);
/**
@@ -301,9 +306,43 @@ function place_pm_into_folder(&$global_privmsgs_rules, $release = false)
$user_message_rules = (int) $user->data['user_message_rules'];
$user_id = (int) $user->data['user_id'];
- $user_rules = $zebra = array();
- if ($user_message_rules)
+ $action_ary = $move_into_folder = array();
+
+ if ($release)
+ {
+ $sql = 'UPDATE ' . PRIVMSGS_TO_TABLE . '
+ SET folder_id = ' . PRIVMSGS_NO_BOX . '
+ WHERE folder_id = ' . PRIVMSGS_HOLD_BOX . "
+ AND user_id = $user_id";
+ $db->sql_query($sql);
+ }
+
+ // Get those messages not yet placed into any box
+ $retrieve_sql = 'SELECT t.*, p.*, u.username, u.user_id, u.group_id
+ FROM ' . PRIVMSGS_TO_TABLE . ' t, ' . PRIVMSGS_TABLE . ' p, ' . USERS_TABLE . " u
+ WHERE t.user_id = $user_id
+ AND p.author_id = u.user_id
+ AND t.folder_id = " . PRIVMSGS_NO_BOX . '
+ AND t.msg_id = p.msg_id';
+
+ // Just place into the appropiate arrays if no rules need to be checked
+ if (!$user_message_rules)
+ {
+ $result = $db->sql_query($retrieve_sql);
+
+ while ($row = $db->sql_fetchrow($result))
+ {
+ $action_ary[$row['msg_id']][] = array('action' => false);
+ $move_into_folder[PRIVMSGS_INBOX][] = $row['msg_id'];
+ }
+ $db->sql_freeresult($result);
+ }
+ else
{
+ $user_rules = $zebra = $check_rows = array();
+ $user_ids = $memberships = array();
+
+ // First of all, grab all rules and retrieve friends/foes
$sql = 'SELECT *
FROM ' . PRIVMSGS_RULES_TABLE . "
WHERE user_id = $user_id";
@@ -324,54 +363,69 @@ function place_pm_into_folder(&$global_privmsgs_rules, $release = false)
}
$db->sql_freeresult($result);
}
- }
- if ($release)
- {
- $sql = 'UPDATE ' . PRIVMSGS_TO_TABLE . '
- SET folder_id = ' . PRIVMSGS_NO_BOX . '
- WHERE folder_id = ' . PRIVMSGS_HOLD_BOX . "
- AND user_id = $user_id";
- $db->sql_query($sql);
- }
+ // Now build a bare-bone check_row array
+ $result = $db->sql_query($retrieve_sql);
- // Get those messages not yet placed into any box
- // @todo question: expand group information to all groups the user/author is in on private message folder?? (user_in_group)
- $sql = 'SELECT t.*, p.*, u.username, u.group_id as author_in_group
- FROM ' . PRIVMSGS_TO_TABLE . ' t, ' . PRIVMSGS_TABLE . ' p, ' . USERS_TABLE . " u
- WHERE t.user_id = $user_id
- AND p.author_id = u.user_id
- AND t.folder_id = " . PRIVMSGS_NO_BOX . '
- AND t.msg_id = p.msg_id';
- $result = $db->sql_query($sql);
+ while ($row = $db->sql_fetchrow($result))
+ {
+ $check_rows[] = array_merge($row, array(
+ 'to' => explode(':', $row['to_address']),
+ 'bcc' => explode(':', $row['bcc_address']),
+ 'friend' => (isset($zebra[$row['author_id']])) ? $zebra[$row['author_id']]['friend'] : 0,
+ 'foe' => (isset($zebra[$row['author_id']])) ? $zebra[$row['author_id']]['foe'] : 0,
+ 'user_in_group' => array($user->data['group_id']),
+ 'author_in_group' => array())
+ );
- $action_ary = $move_into_folder = array();
- while ($row = $db->sql_fetchrow($result))
- {
- $row['to'] = explode(':', $row['to_address']);
- $row['bcc'] = explode(':', $row['bcc_address']);
- $row['friend'] = (isset($zebra[$row['author_id']])) ? $zebra[$row['author_id']]['friend'] : 0;
- $row['foe'] = (isset($zebra[$row['author_id']])) ? $zebra[$row['author_id']]['foe'] : 0;
- $row['user_in_group'] = $user->data['group_id'];
-
- // Check Rule - this should be very quick since we have all informations we need
- $is_match = false;
- foreach ($user_rules as $rule_row)
+ $user_ids[] = $row['user_id'];
+ }
+ $db->sql_freeresult($result);
+
+ // Retrieve user memberships
+ if (sizeof($user_ids))
{
- if (($action = check_rule($global_privmsgs_rules, $rule_row, $row, $user_id)) !== false)
+ $sql = 'SELECT *
+ FROM ' . USER_GROUP_TABLE . '
+ WHERE user_id IN (' . implode(', ', $user_ids) . ')';
+ $result = $db->sql_query($sql);
+
+ while ($row = $db->sql_fetchrow($result))
{
- $is_match = true;
- $action_ary[$row['msg_id']][] = $action;
+ $memberships[$row['user_id']][] = $row['group_id'];
}
+ $db->sql_freeresult($result);
}
-
- if (!$is_match)
+
+ // Now place into the appropiate folder
+ foreach ($check_rows as $row)
{
- $action_ary[$row['msg_id']][] = array('action' => false);
- $move_into_folder[PRIVMSGS_INBOX][] = $row['msg_id'];
+ // Add membership if set
+ if (isset($memberships[$row['author_id']]))
+ {
+ $row['author_in_group'] = $memberships[$row['user_id']];
+ }
+
+ // Check Rule - this should be very quick since we have all informations we need
+ $is_match = false;
+ foreach ($user_rules as $rule_row)
+ {
+ if (($action = check_rule($global_privmsgs_rules, $rule_row, $row, $user_id)) !== false)
+ {
+ $is_match = true;
+ $action_ary[$row['msg_id']][] = $action;
+ }
+ }
+
+ if (!$is_match)
+ {
+ $action_ary[$row['msg_id']][] = array('action' => false);
+ $move_into_folder[PRIVMSGS_INBOX][] = $row['msg_id'];
+ }
}
+
+ unset($user_rules, $zebra, $check_rows, $user_ids, $memberships);
}
- $db->sql_freeresult($result);
// We place actions into arrays, to save queries.
$num_new = $num_unread = 0;
@@ -388,7 +442,7 @@ function place_pm_into_folder(&$global_privmsgs_rules, $release = false)
{
continue;
}
-
+
switch ($rule_ary['action'])
{
case ACTION_PLACE_INTO_FOLDER:
diff --git a/phpBB/includes/ucp/ucp_attachments.php b/phpBB/includes/ucp/ucp_attachments.php
index 8582a92478..c9ae7ed314 100644
--- a/phpBB/includes/ucp/ucp_attachments.php
+++ b/phpBB/includes/ucp/ucp_attachments.php
@@ -160,6 +160,7 @@ class ucp_attachments
);
$this->tpl_name = 'ucp_attachments';
+ $this->page_title = 'UCP_ATTACHMENTS';
}
}
diff --git a/phpBB/includes/ucp/ucp_groups.php b/phpBB/includes/ucp/ucp_groups.php
index 3f30ec2d37..40e5fca5d3 100644
--- a/phpBB/includes/ucp/ucp_groups.php
+++ b/phpBB/includes/ucp/ucp_groups.php
@@ -514,6 +514,8 @@ class ucp_groups
if (!($error = group_create($group_id, $group_type, $group_name, $group_desc, $group_attributes, $allow_desc_bbcode, $allow_desc_urls, $allow_desc_smilies)))
{
+ $cache->destroy('sql', GROUPS_TABLE);
+
$message = ($action == 'edit') ? 'GROUP_UPDATED' : 'GROUP_CREATED';
trigger_error($user->lang[$message] . $return_page);
}
@@ -919,6 +921,7 @@ class ucp_groups
}
$this->tpl_name = 'ucp_groups_' . $mode;
+ $this->page_title = 'UCP_GROUPS_' . strtoupper($mode);
}
}
diff --git a/phpBB/includes/ucp/ucp_main.php b/phpBB/includes/ucp/ucp_main.php
index a0eec4b5ad..9ba40d1a50 100644
--- a/phpBB/includes/ucp/ucp_main.php
+++ b/phpBB/includes/ucp/ucp_main.php
@@ -181,6 +181,7 @@ class ucp_main
case 'subscribed':
include($phpbb_root_path . 'includes/functions_display.' . $phpEx);
+
$user->add_lang('viewforum');
$unwatch = (isset($_POST['unwatch'])) ? true : false;
@@ -464,6 +465,7 @@ class ucp_main
}
include($phpbb_root_path . 'includes/functions_display.' . $phpEx);
+
$user->add_lang('viewforum');
$move_up = request_var('move_up', 0);
@@ -785,6 +787,7 @@ class ucp_main
// Set desired template
$this->tpl_name = 'ucp_main_' . $mode;
+ $this->page_title = 'UCP_MAIN_' . strtoupper($mode);
}
}
diff --git a/phpBB/includes/ucp/ucp_pm.php b/phpBB/includes/ucp/ucp_pm.php
index b2dd23b9d8..73b81b0c17 100644
--- a/phpBB/includes/ucp/ucp_pm.php
+++ b/phpBB/includes/ucp/ucp_pm.php
@@ -126,7 +126,7 @@ class ucp_pm
$sql = 'SELECT group_message_limit
FROM ' . GROUPS_TABLE . '
WHERE group_id = ' . $user->data['group_id'];
- $result = $db->sql_query($sql);
+ $result = $db->sql_query($sql, 3600);
$message_limit = (int) $db->sql_fetchfield('group_message_limit');
$db->sql_freeresult($result);
@@ -162,7 +162,7 @@ class ucp_pm
$sql = 'SELECT group_message_limit
FROM ' . GROUPS_TABLE . '
WHERE group_id = ' . $user->data['group_id'];
- $result = $db->sql_query($sql);
+ $result = $db->sql_query($sql, 3600);
$message_limit = (int) $db->sql_fetchfield('group_message_limit');
$db->sql_freeresult($result);
@@ -401,6 +401,7 @@ class ucp_pm
// Set desired template
$this->tpl_name = $tpl_file;
+ $this->page_title = 'UCP_PM_' . strtoupper($mode);
}
}
diff --git a/phpBB/includes/ucp/ucp_pm_options.php b/phpBB/includes/ucp/ucp_pm_options.php
index 3362b5d9b4..c9e911b5f4 100644
--- a/phpBB/includes/ucp/ucp_pm_options.php
+++ b/phpBB/includes/ucp/ucp_pm_options.php
@@ -741,7 +741,8 @@ function show_defined_rules($user_id, $check_lang, $rule_lang, $action_lang, $fo
$sql = 'SELECT *
FROM ' . PRIVMSGS_RULES_TABLE . '
- WHERE user_id = ' . $user_id;
+ WHERE user_id = ' . $user_id . '
+ ORDER BY rule_id ASC';
$result = $db->sql_query($sql);
$count = 0;
diff --git a/phpBB/includes/ucp/ucp_prefs.php b/phpBB/includes/ucp/ucp_prefs.php
index a8ca9ad844..577d89a62a 100644
--- a/phpBB/includes/ucp/ucp_prefs.php
+++ b/phpBB/includes/ucp/ucp_prefs.php
@@ -342,6 +342,7 @@ class ucp_prefs
);
$this->tpl_name = 'ucp_prefs_' . $mode;
+ $this->page_title = 'UCP_PREFS_' . strtoupper($mode);
}
}
diff --git a/phpBB/includes/ucp/ucp_profile.php b/phpBB/includes/ucp/ucp_profile.php
index ef39ba81a3..8fa3d1b7a7 100644
--- a/phpBB/includes/ucp/ucp_profile.php
+++ b/phpBB/includes/ucp/ucp_profile.php
@@ -672,6 +672,7 @@ class ucp_profile
// Set desired template
$this->tpl_name = 'ucp_profile_' . $mode;
+ $this->page_title = 'UCP_PROFILE_' . strtoupper($mode);
}
}
diff --git a/phpBB/includes/ucp/ucp_register.php b/phpBB/includes/ucp/ucp_register.php
index 8dd482a0c1..8d59a976be 100644
--- a/phpBB/includes/ucp/ucp_register.php
+++ b/phpBB/includes/ucp/ucp_register.php
@@ -470,6 +470,7 @@ class ucp_register
//
$this->tpl_name = 'ucp_register';
+ $this->page_title = 'UCP_REGISTRATION';
}
}
diff --git a/phpBB/includes/ucp/ucp_remind.php b/phpBB/includes/ucp/ucp_remind.php
index 0bdfb685a3..838cc810ab 100644
--- a/phpBB/includes/ucp/ucp_remind.php
+++ b/phpBB/includes/ucp/ucp_remind.php
@@ -92,6 +92,7 @@ class ucp_remind
);
$this->tpl_name = 'ucp_remind';
+ $this->page_title = 'UCP_REMIND';
}
}
diff --git a/phpBB/includes/ucp/ucp_resend.php b/phpBB/includes/ucp/ucp_resend.php
index 51dd2ea4f2..2080feb8be 100644
--- a/phpBB/includes/ucp/ucp_resend.php
+++ b/phpBB/includes/ucp/ucp_resend.php
@@ -140,6 +140,7 @@ class ucp_resend
);
$this->tpl_name = 'ucp_resend';
+ $this->page_title = 'UCP_RESEND';
}
}
diff --git a/phpBB/includes/ucp/ucp_zebra.php b/phpBB/includes/ucp/ucp_zebra.php
index 9b2de97b8e..df86aae6e4 100644
--- a/phpBB/includes/ucp/ucp_zebra.php
+++ b/phpBB/includes/ucp/ucp_zebra.php
@@ -210,6 +210,7 @@ class ucp_zebra
);
$this->tpl_name = 'ucp_zebra_' . $mode;
+ $this->page_title = 'UCP_ZEBRA_' . strtoupper($mode);
}
}
diff --git a/phpBB/language/en/common.php b/phpBB/language/en/common.php
index 1cd00cd530..9160a1e976 100644
--- a/phpBB/language/en/common.php
+++ b/phpBB/language/en/common.php
@@ -94,6 +94,7 @@ $lang = array_merge($lang, array(
'CHANGE' => 'Change',
'CLICK_VIEW_PRIVMSG' => '%sReturn to your Inbox%s',
'CLOSE_WINDOW' => 'Close window',
+ 'COLOUR_SWATCH' => 'Colour swatch',
'CONFIRM' => 'Confirm',
'CONFIRM_CODE' => 'Confirmation code',
'CONFIRM_CODE_EXPLAIN' => 'Enter the code exactly as you see it in the image, it is case insensitive.',
diff --git a/phpBB/language/en/ucp.php b/phpBB/language/en/ucp.php
index 293f5d192b..aa9cc1c6cc 100644
--- a/phpBB/language/en/ucp.php
+++ b/phpBB/language/en/ucp.php
@@ -477,7 +477,7 @@ $lang = array_merge($lang, array(
'ANSWERED' => 'answered',
'FORWARDED' => 'forwarded',
'REPORTED' => 'reported',
- 'TO_GROUP' => 'to usergroup',
+ 'TO_GROUP' => 'to my default usergroup',
'TO_ME' => 'to me'
),
diff --git a/phpBB/mcp.php b/phpBB/mcp.php
index 1ecdabbf24..0293d161e4 100644
--- a/phpBB/mcp.php
+++ b/phpBB/mcp.php
@@ -218,8 +218,8 @@ $module->load_active();
// Assign data to the template engine for the list of modules
$module->assign_tpl_vars(append_sid("{$phpbb_root_path}mcp.$phpEx"));
-// Generate the page
-$module->display($module->get_page_title());
+// Generate the page, do not display/query online list
+$module->display($module->get_page_title(), false);
/**
diff --git a/phpBB/ucp.php b/phpBB/ucp.php
index c8a318589b..cf75233172 100755
--- a/phpBB/ucp.php
+++ b/phpBB/ucp.php
@@ -111,7 +111,8 @@ switch ($mode)
'body' => 'ucp_agreement.html')
);
- page_header($user->lang[$title]);
+ // Disable online list
+ page_header($user->lang[$title], false);
$template->assign_vars(array(
'S_AGREEMENT' => true,
@@ -318,15 +319,8 @@ $module->load_active();
// Assign data to the template engine for the list of modules
$module->assign_tpl_vars(append_sid("{$phpbb_root_path}ucp.$phpEx"));
-// Generate the page
-page_header($user->lang['UCP_MAIN']);
-
-$template->set_filenames(array(
- 'body' => $module->get_tpl_name())
-);
-
-page_footer();
-
+// Generate the page, do not display/query online list
+$module->display($module->get_page_title(), false);
/**
* Function for assigning a template var if the zebra module got included