aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/modules
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/modules')
-rw-r--r--phpBB/modules/acp/acp_attachments.php8
-rw-r--r--phpBB/modules/acp/acp_ban.php2
-rw-r--r--phpBB/modules/acp/acp_bbcodes.php12
-rw-r--r--phpBB/modules/acp/acp_bots.php10
-rw-r--r--phpBB/modules/acp/acp_database.php4
-rw-r--r--phpBB/modules/acp/acp_disallow.php6
-rw-r--r--phpBB/modules/acp/acp_email.php2
-rw-r--r--phpBB/modules/acp/acp_forums.php18
-rw-r--r--phpBB/modules/acp/acp_groups.php4
-rw-r--r--phpBB/modules/acp/acp_icons.php18
-rw-r--r--phpBB/modules/acp/acp_language.php6
-rw-r--r--phpBB/modules/acp/acp_logs.php2
-rw-r--r--phpBB/modules/acp/acp_main.php3
-rw-r--r--phpBB/modules/acp/acp_modules.php6
-rw-r--r--phpBB/modules/acp/acp_permission_roles.php2
-rw-r--r--phpBB/modules/acp/acp_permissions.php2
-rw-r--r--phpBB/modules/acp/acp_profile.php2
-rw-r--r--phpBB/modules/acp/acp_prune.php4
-rw-r--r--phpBB/modules/acp/acp_ranks.php6
-rw-r--r--phpBB/modules/acp/acp_reasons.php2
-rw-r--r--phpBB/modules/acp/acp_search.php4
-rw-r--r--phpBB/modules/acp/acp_styles.php40
-rw-r--r--phpBB/modules/acp/acp_update.php2
-rw-r--r--phpBB/modules/acp/acp_users.php2
-rw-r--r--phpBB/modules/acp/acp_words.php6
-rw-r--r--phpBB/modules/acp/auth.php10
-rw-r--r--phpBB/modules/mcp/mcp_ban.php2
-rw-r--r--phpBB/modules/mcp/mcp_forum.php2
-rw-r--r--phpBB/modules/mcp/mcp_post.php2
-rw-r--r--phpBB/modules/mcp/mcp_queue.php2
-rw-r--r--phpBB/modules/mcp/mcp_reports.php2
-rw-r--r--phpBB/modules/mcp/mcp_topic.php2
-rw-r--r--phpBB/modules/ucp/ucp_groups.php4
-rw-r--r--phpBB/modules/ucp/ucp_pm_viewfolder.php2
-rw-r--r--phpBB/modules/ucp/ucp_pm_viewmessage.php4
35 files changed, 101 insertions, 104 deletions
diff --git a/phpBB/modules/acp/acp_attachments.php b/phpBB/modules/acp/acp_attachments.php
index 6b827a91fb..a447ffd923 100644
--- a/phpBB/modules/acp/acp_attachments.php
+++ b/phpBB/modules/acp/acp_attachments.php
@@ -26,7 +26,7 @@ class acp_attachments
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang(array('posting', 'viewtopic', 'acp/attachments'));
@@ -396,7 +396,7 @@ class acp_attachments
$notify[] = $user->lang['EXTENSIONS_UPDATED'];
}
- $cache->destroy('_extensions');
+ phpbb::$acm->destroy('extensions');
}
$template->assign_vars(array(
@@ -575,7 +575,7 @@ class acp_attachments
$db->sql_query($sql);
}
- $cache->destroy('_extensions');
+ phpbb::$acm->destroy('extensions');
if (!sizeof($error))
{
@@ -621,7 +621,7 @@ class acp_attachments
add_log('admin', 'LOG_ATTACH_EXTGROUP_DEL', $group_name);
- $cache->destroy('_extensions');
+ phpbb::$acm->destroy('extensions');
trigger_error($user->lang['EXTENSION_GROUP_DELETED'] . adm_back_link($this->u_action));
}
diff --git a/phpBB/modules/acp/acp_ban.php b/phpBB/modules/acp/acp_ban.php
index 578ddd02d8..c6ce71371d 100644
--- a/phpBB/modules/acp/acp_ban.php
+++ b/phpBB/modules/acp/acp_ban.php
@@ -25,7 +25,7 @@ class acp_ban
function main($id, $mode)
{
- global $config, $db, $user, $auth, $template, $cache;
+ global $config, $db, $user, $auth, $template;
include(PHPBB_ROOT_PATH . 'includes/functions_user.' . PHP_EXT);
diff --git a/phpBB/modules/acp/acp_bbcodes.php b/phpBB/modules/acp/acp_bbcodes.php
index 4118e5f919..b76d4f5e27 100644
--- a/phpBB/modules/acp/acp_bbcodes.php
+++ b/phpBB/modules/acp/acp_bbcodes.php
@@ -25,7 +25,7 @@ class acp_bbcodes
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang('acp/posting');
@@ -167,8 +167,8 @@ class acp_bbcodes
{
trigger_error($user->lang['BBCODE_TAG_DEF_TOO_LONG'] . adm_back_link($this->u_action), E_USER_WARNING);
}
-
-
+
+
if (strlen($bbcode_helpline) > 255)
{
trigger_error($user->lang['BBCODE_HELPLINE_TOO_LONG'] . adm_back_link($this->u_action), E_USER_WARNING);
@@ -217,7 +217,7 @@ class acp_bbcodes
$sql_ary['bbcode_id'] = (int) $bbcode_id;
$db->sql_query('INSERT INTO ' . BBCODES_TABLE . $db->sql_build_array('INSERT', $sql_ary));
- $cache->destroy('sql', BBCODES_TABLE);
+ phpbb::$acm->destroy_sql(BBCODES_TABLE);
$lang = 'BBCODE_ADDED';
$log_action = 'LOG_BBCODE_ADD';
@@ -228,7 +228,7 @@ class acp_bbcodes
SET ' . $db->sql_build_array('UPDATE', $sql_ary) . '
WHERE bbcode_id = ' . $bbcode_id;
$db->sql_query($sql);
- $cache->destroy('sql', BBCODES_TABLE);
+ phpbb::$acm->destroy_sql(BBCODES_TABLE);
$lang = 'BBCODE_EDITED';
$log_action = 'LOG_BBCODE_EDIT';
@@ -254,7 +254,7 @@ class acp_bbcodes
if (confirm_box(true))
{
$db->sql_query('DELETE FROM ' . BBCODES_TABLE . " WHERE bbcode_id = $bbcode_id");
- $cache->destroy('sql', BBCODES_TABLE);
+ phpbb::$acm->destroy_sql(BBCODES_TABLE);
add_log('admin', 'LOG_BBCODE_DELETE', $row['bbcode_tag']);
}
else
diff --git a/phpBB/modules/acp/acp_bots.php b/phpBB/modules/acp/acp_bots.php
index b1a0f3f7cd..7a23ca09c5 100644
--- a/phpBB/modules/acp/acp_bots.php
+++ b/phpBB/modules/acp/acp_bots.php
@@ -25,7 +25,7 @@ class acp_bots
function main($id, $mode)
{
- global $config, $db, $user, $auth, $template, $cache;
+ global $config, $db, $user, $auth, $template;
$action = request_var('action', '');
$submit = phpbb_request::is_set_post('submit');
@@ -64,7 +64,7 @@ class acp_bots
$db->sql_query($sql);
}
- $cache->destroy('_bots');
+ phpbb::$acm->destroy('bots');
break;
case 'deactivate':
@@ -78,7 +78,7 @@ class acp_bots
$db->sql_query($sql);
}
- $cache->destroy('_bots');
+ phpbb::$acm->destroy('bots');
break;
case 'delete':
@@ -121,7 +121,7 @@ class acp_bots
$db->sql_transaction('commit');
- $cache->destroy('_bots');
+ phpbb::$acm->destroy('bots');
add_log('admin', 'LOG_BOT_DELETE', implode(', ', $bot_name_ary));
trigger_error($user->lang['BOT_DELETED'] . adm_back_link($this->u_action));
@@ -290,7 +290,7 @@ class acp_bots
$log = 'UPDATED';
}
- $cache->destroy('_bots');
+ phpbb::$acm->destroy('bots');
add_log('admin', 'LOG_BOT_' . $log, $bot_row['bot_name']);
trigger_error($user->lang['BOT_' . $log] . adm_back_link($this->u_action));
diff --git a/phpBB/modules/acp/acp_database.php b/phpBB/modules/acp/acp_database.php
index 9261998d80..837e7280e2 100644
--- a/phpBB/modules/acp/acp_database.php
+++ b/phpBB/modules/acp/acp_database.php
@@ -25,7 +25,7 @@ class acp_database
function main($id, $mode)
{
- global $cache, $db, $user, $auth, $template, $table_prefix, $config;
+ global $db, $user, $auth, $template, $table_prefix, $config;
$user->add_lang('acp/database');
@@ -399,7 +399,7 @@ class acp_database
$close($fp);
// Purge the cache due to updated data
- $cache->purge();
+ phpbb::$acm->purge();
add_log('admin', 'LOG_DB_RESTORE');
trigger_error($user->lang['RESTORE_SUCCESS'] . adm_back_link($this->u_action));
diff --git a/phpBB/modules/acp/acp_disallow.php b/phpBB/modules/acp/acp_disallow.php
index 774fef67fc..507cbbdf15 100644
--- a/phpBB/modules/acp/acp_disallow.php
+++ b/phpBB/modules/acp/acp_disallow.php
@@ -25,7 +25,7 @@ class acp_disallow
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
include(PHPBB_ROOT_PATH . 'includes/functions_user.' . PHP_EXT);
@@ -58,7 +58,7 @@ class acp_disallow
$sql = 'INSERT INTO ' . DISALLOW_TABLE . ' ' . $db->sql_build_array('INSERT', array('disallow_username' => $disallowed_user));
$db->sql_query($sql);
- $cache->destroy('_disallowed_usernames');
+ phpbb::$acm->destroy('disallowed_usernames');
$message = $user->lang['DISALLOW_SUCCESSFUL'];
add_log('admin', 'LOG_DISALLOW_ADD', str_replace('%', '*', $disallowed_user));
@@ -78,7 +78,7 @@ class acp_disallow
WHERE disallow_id = ' . $disallowed_id;
$db->sql_query($sql);
- $cache->destroy('_disallowed_usernames');
+ phpbb::$acm->destroy('disallowed_usernames');
add_log('admin', 'LOG_DISALLOW_DELETE');
diff --git a/phpBB/modules/acp/acp_email.php b/phpBB/modules/acp/acp_email.php
index c516c77f6c..3e9be9e34c 100644
--- a/phpBB/modules/acp/acp_email.php
+++ b/phpBB/modules/acp/acp_email.php
@@ -25,7 +25,7 @@ class acp_email
function main($id, $mode)
{
- global $config, $db, $user, $auth, $template, $cache;
+ global $config, $db, $user, $auth, $template;
$user->add_lang('acp/email');
$this->tpl_name = 'acp_email';
diff --git a/phpBB/modules/acp/acp_forums.php b/phpBB/modules/acp/acp_forums.php
index 303080a5e0..30a038c611 100644
--- a/phpBB/modules/acp/acp_forums.php
+++ b/phpBB/modules/acp/acp_forums.php
@@ -26,7 +26,7 @@ class acp_forums
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang('acp/forums');
$this->tpl_name = 'acp_forums';
@@ -96,7 +96,7 @@ class acp_forums
}
$auth->acl_clear_prefetch();
- $cache->destroy('sql', FORUMS_TABLE);
+ phpbb::$acm->destroy_sql(FORUMS_TABLE);
trigger_error($user->lang['FORUM_DELETED'] . adm_back_link($this->u_action . '&parent_id=' . $this->parent_id));
@@ -246,7 +246,7 @@ class acp_forums
}
$auth->acl_clear_prefetch();
- $cache->destroy('sql', FORUMS_TABLE);
+ phpbb::$acm->destroy_sql(FORUMS_TABLE);
$acl_url = '&mode=setting_forum_local&forum_id[]=' . $forum_data['forum_id'];
@@ -298,7 +298,7 @@ class acp_forums
if ($move_forum_name !== false)
{
add_log('admin', 'LOG_FORUM_' . strtoupper($action), $row['forum_name'], $move_forum_name);
- $cache->destroy('sql', FORUMS_TABLE);
+ phpbb::$acm->destroy_sql(FORUMS_TABLE);
}
break;
@@ -404,7 +404,7 @@ class acp_forums
sync('forum', 'forum_id', $forum_id, false, true);
add_log('admin', 'LOG_FORUM_SYNC', $row['forum_name']);
- $cache->destroy('sql', FORUMS_TABLE);
+ phpbb::$acm->destroy_sql(FORUMS_TABLE);
$template->assign_var('L_FORUM_RESYNCED', sprintf($user->lang['FORUM_RESYNCED'], $row['forum_name']));
@@ -887,7 +887,7 @@ class acp_forums
*/
function update_forum_data(&$forum_data)
{
- global $db, $user, $cache;
+ global $db, $user;
$errors = array();
@@ -1138,7 +1138,7 @@ class acp_forums
}
$db->sql_freeresult($result);
- $cache->destroy('_extensions');
+ phpbb::$acm->destroy('extensions');
}
}
else if ($action_subforums == 'move')
@@ -1387,7 +1387,7 @@ class acp_forums
*/
function delete_forum($forum_id, $action_posts = 'delete', $action_subforums = 'delete', $posts_to_id = 0, $subforums_to_id = 0)
{
- global $db, $user, $cache;
+ global $db, $user;
$forum_data = $this->get_forum_info($forum_id);
@@ -1577,7 +1577,7 @@ class acp_forums
}
$db->sql_freeresult($result);
- $cache->destroy('_extensions');
+ phpbb::$acm->destroy('extensions');
$log_action = implode('_', array($log_action_posts, $log_action_forums));
diff --git a/phpBB/modules/acp/acp_groups.php b/phpBB/modules/acp/acp_groups.php
index f01ca2290c..fce4ba7e55 100644
--- a/phpBB/modules/acp/acp_groups.php
+++ b/phpBB/modules/acp/acp_groups.php
@@ -25,7 +25,7 @@ class acp_groups
function main($id, $mode)
{
- global $config, $db, $user, $auth, $template, $cache, $file_uploads;
+ global $config, $db, $user, $auth, $template, $file_uploads;
$user->add_lang('acp/groups');
$this->tpl_name = 'acp_groups';
@@ -458,7 +458,7 @@ class acp_groups
}
}
- $cache->destroy('sql', GROUPS_TABLE);
+ phpbb::$acm->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/modules/acp/acp_icons.php b/phpBB/modules/acp/acp_icons.php
index 1da9bc0910..c766ab5540 100644
--- a/phpBB/modules/acp/acp_icons.php
+++ b/phpBB/modules/acp/acp_icons.php
@@ -26,7 +26,7 @@ class acp_icons
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang('acp/posting');
@@ -429,8 +429,8 @@ class acp_icons
}
}
- $cache->destroy('_icons');
- $cache->destroy('sql', $table);
+ phpbb::$acm->destroy('icons');
+ phpbb::$acm->destroy_sql($table);
$level = E_USER_NOTICE;
switch ($icons_updated)
@@ -607,8 +607,8 @@ class acp_icons
}
}
- $cache->destroy('_icons');
- $cache->destroy('sql', $table);
+ phpbb::$acm->destroy('icons');
+ phpbb::$acm->destroy_sql($table);
trigger_error($user->lang[$lang . '_IMPORT_SUCCESS'] . adm_back_link($this->u_action));
}
@@ -729,8 +729,8 @@ class acp_icons
$notice = $user->lang[$lang . '_DELETED'];
- $cache->destroy('_icons');
- $cache->destroy('sql', $table);
+ phpbb::$acm->destroy('icons');
+ phpbb::$acm->destroy_sql($table);
}
else
{
@@ -781,8 +781,8 @@ class acp_icons
$db->sql_query($sql);
}
- $cache->destroy('_icons');
- $cache->destroy('sql', $table);
+ phpbb::$acm->destroy('icons');
+ phpbb::$acm->destroy_sql($table);
break;
}
diff --git a/phpBB/modules/acp/acp_language.php b/phpBB/modules/acp/acp_language.php
index cdc8a798e1..fd33057e07 100644
--- a/phpBB/modules/acp/acp_language.php
+++ b/phpBB/modules/acp/acp_language.php
@@ -31,7 +31,7 @@ class acp_language
function main($id, $mode)
{
- global $config, $db, $user, $auth, $template, $cache;
+ global $config, $db, $user, $auth, $template;
global $safe_mode, $file_uploads;
/**
@@ -796,7 +796,7 @@ class acp_language
$sql = 'DELETE FROM ' . STYLES_IMAGESET_DATA_TABLE . " WHERE image_lang = '" . $db->sql_escape($row['lang_iso']) . "'";
$result = $db->sql_query($sql);
- $cache->destroy('sql', STYLES_IMAGESET_DATA_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_IMAGESET_DATA_TABLE);
add_log('admin', 'LOG_LANGUAGE_PACK_DELETED', $row['lang_english_name']);
@@ -908,7 +908,7 @@ class acp_language
if (sizeof($sql_ary))
{
$db->sql_multi_insert(STYLES_IMAGESET_DATA_TABLE, $sql_ary);
- $cache->destroy('sql', STYLES_IMAGESET_DATA_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_IMAGESET_DATA_TABLE);
}
// Now let's copy the default language entries for custom profile fields for this new language - makes admin's life easier.
diff --git a/phpBB/modules/acp/acp_logs.php b/phpBB/modules/acp/acp_logs.php
index 0b2ec76271..95442b336c 100644
--- a/phpBB/modules/acp/acp_logs.php
+++ b/phpBB/modules/acp/acp_logs.php
@@ -25,7 +25,7 @@ class acp_logs
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang('mcp');
diff --git a/phpBB/modules/acp/acp_main.php b/phpBB/modules/acp/acp_main.php
index 5e7e998f34..78ada1d09d 100644
--- a/phpBB/modules/acp/acp_main.php
+++ b/phpBB/modules/acp/acp_main.php
@@ -328,8 +328,7 @@ class acp_main
trigger_error($user->lang['NO_AUTH_OPERATION'] . adm_back_link($this->u_action), E_USER_WARNING);
}
- global $cache;
- $cache->purge();
+ phpbb::$acm->purge();
// Clear permissions
$auth->acl_clear_prefetch();
diff --git a/phpBB/modules/acp/acp_modules.php b/phpBB/modules/acp/acp_modules.php
index 093216c330..e04961099c 100644
--- a/phpBB/modules/acp/acp_modules.php
+++ b/phpBB/modules/acp/acp_modules.php
@@ -720,15 +720,13 @@ class acp_modules
*/
function remove_cache_file()
{
- global $cache;
-
// Sanitise for future path use, it's escaped as appropriate for queries
$p_class = str_replace(array('.', '/', '\\'), '', basename($this->module_class));
- $cache->destroy('_modules_' . $p_class);
+ phpbb::$acm->destroy('modules_' . $p_class);
// Additionally remove sql cache
- $cache->destroy('sql', MODULES_TABLE);
+ phpbb::$acm->destroy_sql(MODULES_TABLE);
}
/**
diff --git a/phpBB/modules/acp/acp_permission_roles.php b/phpBB/modules/acp/acp_permission_roles.php
index 00bdcedcc6..8348c622c5 100644
--- a/phpBB/modules/acp/acp_permission_roles.php
+++ b/phpBB/modules/acp/acp_permission_roles.php
@@ -25,7 +25,7 @@ class acp_permission_roles
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
include_once(PHPBB_ROOT_PATH . 'includes/functions_user.' . PHP_EXT);
include_once(PHPBB_ROOT_PATH . 'includes/acp/auth.' . PHP_EXT);
diff --git a/phpBB/modules/acp/acp_permissions.php b/phpBB/modules/acp/acp_permissions.php
index 9b3d966ebd..8b3b424ce8 100644
--- a/phpBB/modules/acp/acp_permissions.php
+++ b/phpBB/modules/acp/acp_permissions.php
@@ -26,7 +26,7 @@ class acp_permissions
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
include_once(PHPBB_ROOT_PATH . 'includes/functions_user.' . PHP_EXT);
include_once(PHPBB_ROOT_PATH . 'includes/acp/auth.' . PHP_EXT);
diff --git a/phpBB/modules/acp/acp_profile.php b/phpBB/modules/acp/acp_profile.php
index 629ac34e43..75bbd1ab14 100644
--- a/phpBB/modules/acp/acp_profile.php
+++ b/phpBB/modules/acp/acp_profile.php
@@ -28,7 +28,7 @@ class acp_profile
function main($id, $mode)
{
- global $config, $db, $user, $auth, $template, $cache;
+ global $config, $db, $user, $auth, $template;
include(PHPBB_ROOT_PATH . 'includes/functions_posting.' . PHP_EXT);
include(PHPBB_ROOT_PATH . 'includes/functions_user.' . PHP_EXT);
diff --git a/phpBB/modules/acp/acp_prune.php b/phpBB/modules/acp/acp_prune.php
index 91d9a371c0..0f6fa9933d 100644
--- a/phpBB/modules/acp/acp_prune.php
+++ b/phpBB/modules/acp/acp_prune.php
@@ -51,7 +51,7 @@ class acp_prune
*/
function prune_forums($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$all_forums = request_var('all_forums', 0);
$forum_id = request_var('f', array(0));
@@ -227,7 +227,7 @@ class acp_prune
*/
function prune_users($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang('memberlist');
diff --git a/phpBB/modules/acp/acp_ranks.php b/phpBB/modules/acp/acp_ranks.php
index d779132d6e..64ed46cc96 100644
--- a/phpBB/modules/acp/acp_ranks.php
+++ b/phpBB/modules/acp/acp_ranks.php
@@ -25,7 +25,7 @@ class acp_ranks
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang('acp/posting');
@@ -88,7 +88,7 @@ class acp_ranks
}
$db->sql_query($sql);
- $cache->destroy('_ranks');
+ phpbb::$acm->destroy('ranks');
trigger_error($message . adm_back_link($this->u_action));
@@ -119,7 +119,7 @@ class acp_ranks
WHERE user_rank = $rank_id";
$db->sql_query($sql);
- $cache->destroy('_ranks');
+ phpbb::$acm->destroy('ranks');
add_log('admin', 'LOG_RANK_REMOVED', $rank_title);
}
diff --git a/phpBB/modules/acp/acp_reasons.php b/phpBB/modules/acp/acp_reasons.php
index 305f4c615e..1c80fcfa40 100644
--- a/phpBB/modules/acp/acp_reasons.php
+++ b/phpBB/modules/acp/acp_reasons.php
@@ -25,7 +25,7 @@ class acp_reasons
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang(array('mcp', 'acp/posting'));
diff --git a/phpBB/modules/acp/acp_search.php b/phpBB/modules/acp/acp_search.php
index aa9159f8e8..380890ec64 100644
--- a/phpBB/modules/acp/acp_search.php
+++ b/phpBB/modules/acp/acp_search.php
@@ -50,7 +50,7 @@ class acp_search
function settings($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$submit = phpbb_request::is_set_post('submit');
@@ -226,7 +226,7 @@ class acp_search
function index($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$action = request_var('action', array('' => false));
if (sizeof($action))
diff --git a/phpBB/modules/acp/acp_styles.php b/phpBB/modules/acp/acp_styles.php
index 4eb0928716..17c33c9c82 100644
--- a/phpBB/modules/acp/acp_styles.php
+++ b/phpBB/modules/acp/acp_styles.php
@@ -31,7 +31,7 @@ class acp_styles
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
// Hardcoded template bitfield to add for new templates
$bitfield = new bitfield();
@@ -300,7 +300,7 @@ parse_css_file = {PARSE_CSS_FILE}
WHERE theme_id = $style_id";
$db->sql_query($sql);
- $cache->destroy('sql', STYLES_THEME_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_THEME_TABLE);
add_log('admin', 'LOG_THEME_REFRESHED', $theme_row['theme_name']);
trigger_error($user->lang['THEME_REFRESHED'] . adm_back_link($this->u_action));
@@ -447,7 +447,7 @@ parse_css_file = {PARSE_CSS_FILE}
$db->sql_transaction('commit');
- $cache->destroy('sql', STYLES_IMAGESET_DATA_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_IMAGESET_DATA_TABLE);
add_log('admin', 'LOG_IMAGESET_REFRESHED', $imageset_row['imageset_name']);
trigger_error($user->lang['IMAGESET_REFRESHED'] . adm_back_link($this->u_action));
@@ -631,7 +631,7 @@ parse_css_file = {PARSE_CSS_FILE}
*/
function edit_template($template_id)
{
- global $config, $db, $cache, $user, $template, $safe_mode;
+ global $config, $db, $user, $template, $safe_mode;
if (defined('PHPBB_DISABLE_ACP_EDITOR'))
{
@@ -692,7 +692,7 @@ parse_css_file = {PARSE_CSS_FILE}
// destroy the cached version of the template (filename without extension)
$this->clear_template_cache($template_info, array(substr($template_file, 0, -5)));
- $cache->destroy('sql', STYLES_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_TABLE);
add_log('admin', 'LOG_TEMPLATE_EDIT', $template_info['template_name'], $template_file);
trigger_error($user->lang['TEMPLATE_FILE_UPDATED'] . $additional . adm_back_link($this->u_action . "&action=edit&id=$template_id&text_rows=$text_rows&template_file=$template_file"));
@@ -801,7 +801,7 @@ parse_css_file = {PARSE_CSS_FILE}
*/
function template_cache($template_id)
{
- global $config, $db, $cache, $user, $template;
+ global $config, $db, $user, $template;
$source = str_replace('/', '.', request_var('source', ''));
$file_ary = array_diff(request_var('delete', array('')), array(''));
@@ -920,7 +920,7 @@ parse_css_file = {PARSE_CSS_FILE}
*/
function edit_theme($theme_id)
{
- global $config, $db, $cache, $user, $template, $safe_mode;
+ global $config, $db, $user, $template, $safe_mode;
$this->page_title = 'EDIT_THEME';
@@ -981,7 +981,7 @@ parse_css_file = {PARSE_CSS_FILE}
WHERE theme_id = ' . $theme_id;
$db->sql_query($sql);
- $cache->destroy('sql', STYLES_THEME_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_THEME_TABLE);
// notify the user if the theme was not stored in the db before his modification
if (!$theme_info['theme_storedb'])
@@ -990,7 +990,7 @@ parse_css_file = {PARSE_CSS_FILE}
$message .= '<br />' . $user->lang['EDIT_THEME_STORED_DB'];
}
}
- $cache->destroy('sql', STYLES_THEME_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_THEME_TABLE);
add_log('admin', (!$theme_info['theme_storedb']) ? 'LOG_THEME_EDIT_FILE' : 'LOG_THEME_EDIT', $theme_info['theme_name'], (!$theme_info['theme_storedb']) ? $theme_file : '');
trigger_error($message . adm_back_link($this->u_action . "&amp;action=edit&amp;id=$theme_id&amp;template_file=$theme_file&amp;text_rows=$text_rows"));
@@ -1107,7 +1107,7 @@ parse_css_file = {PARSE_CSS_FILE}
*/
function edit_imageset($imageset_id)
{
- global $db, $user, $cache, $template;
+ global $db, $user, $template;
$this->page_title = 'EDIT_IMAGESET';
@@ -1232,7 +1232,7 @@ parse_css_file = {PARSE_CSS_FILE}
$db->sql_query('INSERT INTO ' . STYLES_IMAGESET_DATA_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary));
}
- $cache->destroy('sql', STYLES_IMAGESET_DATA_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_IMAGESET_DATA_TABLE);
add_log('admin', 'LOG_IMAGESET_EDIT', $imageset_name);
@@ -1376,7 +1376,7 @@ parse_css_file = {PARSE_CSS_FILE}
*/
function remove($mode, $style_id)
{
- global $db, $template, $user, $cache, $config;
+ global $db, $template, $user, $config;
$new_id = request_var('new_id', 0);
$update = phpbb_request::is_set_post('update');
@@ -1480,7 +1480,7 @@ parse_css_file = {PARSE_CSS_FILE}
$db->sql_query($sql);
}
- $cache->destroy('sql', STYLES_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_TABLE);
add_log('admin', 'LOG_' . $l_prefix . '_DELETE', $style_row[$mode . '_name']);
$message = ($mode != 'style') ? $l_prefix . '_DELETED_FS' : $l_prefix . '_DELETED';
@@ -1512,7 +1512,7 @@ parse_css_file = {PARSE_CSS_FILE}
*/
function export($mode, $style_id)
{
- global $db, $template, $user, $cache, $config;
+ global $db, $template, $user, $config;
$update = phpbb_request::is_set_post('update');
@@ -1909,7 +1909,7 @@ parse_css_file = {PARSE_CSS_FILE}
*/
function details($mode, $style_id)
{
- global $template, $db, $config, $user, $safe_mode, $cache;
+ global $template, $db, $config, $user, $safe_mode;
$update = phpbb_request::is_set_post('update');
$l_type = strtoupper($mode);
@@ -2056,7 +2056,7 @@ parse_css_file = {PARSE_CSS_FILE}
}
}
- $cache->destroy('sql', STYLES_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_TABLE);
add_log('admin', 'LOG_' . $l_type . '_EDIT_DETAILS', $name);
if (sizeof($error))
@@ -2260,7 +2260,7 @@ parse_css_file = {PARSE_CSS_FILE}
*/
function install($mode)
{
- global $config, $db, $cache, $user, $template;
+ global $config, $db, $user, $template;
$l_type = strtoupper($mode);
@@ -2373,7 +2373,7 @@ parse_css_file = {PARSE_CSS_FILE}
if (!sizeof($error))
{
- $cache->destroy('sql', STYLES_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_TABLE);
trigger_error($user->lang[$l_type . '_ADDED'] . adm_back_link($this->u_action));
}
@@ -2415,7 +2415,7 @@ parse_css_file = {PARSE_CSS_FILE}
*/
function add($mode)
{
- global $config, $db, $cache, $user, $template;
+ global $config, $db, $user, $template;
$l_type = strtoupper($mode);
$element_ary = array('template' => STYLES_TEMPLATE_TABLE, 'theme' => STYLES_THEME_TABLE, 'imageset' => STYLES_IMAGESET_TABLE);
@@ -2503,7 +2503,7 @@ parse_css_file = {PARSE_CSS_FILE}
if (!sizeof($error))
{
- $cache->destroy('sql', STYLES_TABLE);
+ phpbb::$acm->destroy_sql(STYLES_TABLE);
trigger_error($user->lang[$l_type . '_ADDED'] . adm_back_link($this->u_action));
}
diff --git a/phpBB/modules/acp/acp_update.php b/phpBB/modules/acp/acp_update.php
index a6440c8364..d021fe5e09 100644
--- a/phpBB/modules/acp/acp_update.php
+++ b/phpBB/modules/acp/acp_update.php
@@ -25,7 +25,7 @@ class acp_update
function main($id, $mode)
{
- global $config, $db, $user, $auth, $template, $cache;
+ global $config, $db, $user, $auth, $template;
$user->add_lang('install');
diff --git a/phpBB/modules/acp/acp_users.php b/phpBB/modules/acp/acp_users.php
index ab48f3b186..0cb973058c 100644
--- a/phpBB/modules/acp/acp_users.php
+++ b/phpBB/modules/acp/acp_users.php
@@ -31,7 +31,7 @@ class acp_users
function main($id, $mode)
{
- global $config, $db, $user, $auth, $template, $cache, $file_uploads;
+ global $config, $db, $user, $auth, $template, $file_uploads;
$user->add_lang(array('posting', 'ucp', 'acp/users'));
$this->tpl_name = 'acp_users';
diff --git a/phpBB/modules/acp/acp_words.php b/phpBB/modules/acp/acp_words.php
index c473d27f13..61728c01af 100644
--- a/phpBB/modules/acp/acp_words.php
+++ b/phpBB/modules/acp/acp_words.php
@@ -26,7 +26,7 @@ class acp_words
function main($id, $mode)
{
- global $db, $user, $auth, $template, $cache, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang('acp/posting');
@@ -106,7 +106,7 @@ class acp_words
$db->sql_query('INSERT INTO ' . WORDS_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary));
}
- $cache->destroy('_word_censors');
+ phpbb::$acm->destroy('word_censors');
$log_action = ($word_id) ? 'LOG_WORD_EDIT' : 'LOG_WORD_ADD';
add_log('admin', $log_action, $word);
@@ -138,7 +138,7 @@ class acp_words
WHERE word_id = $word_id";
$db->sql_query($sql);
- $cache->destroy('_word_censors');
+ phpbb::$acm->destroy('word_censors');
add_log('admin', 'LOG_WORD_DELETE', $deleted_word);
diff --git a/phpBB/modules/acp/auth.php b/phpBB/modules/acp/auth.php
index ee4e45a08d..92e61f0480 100644
--- a/phpBB/modules/acp/auth.php
+++ b/phpBB/modules/acp/auth.php
@@ -27,9 +27,9 @@ class auth_admin extends auth
*/
function __construct()
{
- global $db, $cache;
+ global $db;
- if (($this->acl_options = $cache->get('_acl_options')) === false)
+ if (($this->acl_options = phpbb::$acm->get('acl_options')) === false)
{
$sql = 'SELECT auth_option_id, auth_option, is_global, is_local
FROM ' . ACL_OPTIONS_TABLE . '
@@ -55,7 +55,7 @@ class auth_admin extends auth
}
$db->sql_freeresult($result);
- $cache->put('_acl_options', $this->acl_options);
+ phpbb::$acm->put('acl_options', $this->acl_options);
}
}
@@ -687,7 +687,7 @@ class auth_admin extends auth
*/
public function acl_add_option(array $options)
{
- global $db, $cache;
+ global $db;
$cur_options = array();
@@ -757,7 +757,7 @@ class auth_admin extends auth
$db->sql_multi_insert(ACL_OPTIONS_TABLE, $sql_ary);
- $cache->destroy('_acl_options');
+ phpbb::$acm->destroy('acl_options');
$this->acl_clear_prefetch();
// Because we just changed the options and also purged the options cache, we instantly update/regenerate it for later calls to succeed.
diff --git a/phpBB/modules/mcp/mcp_ban.php b/phpBB/modules/mcp/mcp_ban.php
index 8feab368de..f4f3708799 100644
--- a/phpBB/modules/mcp/mcp_ban.php
+++ b/phpBB/modules/mcp/mcp_ban.php
@@ -25,7 +25,7 @@ class mcp_ban
function main($id, $mode)
{
- global $config, $db, $user, $auth, $template, $cache;
+ global $config, $db, $user, $auth, $template;
include(PHPBB_ROOT_PATH . 'includes/functions_user.' . PHP_EXT);
diff --git a/phpBB/modules/mcp/mcp_forum.php b/phpBB/modules/mcp/mcp_forum.php
index c99ae0c067..2f90e99e93 100644
--- a/phpBB/modules/mcp/mcp_forum.php
+++ b/phpBB/modules/mcp/mcp_forum.php
@@ -21,7 +21,7 @@ if (!defined('IN_PHPBB'))
*/
function mcp_forum_view($id, $mode, $action, $forum_info)
{
- global $template, $db, $user, $auth, $cache, $module, $config;
+ global $template, $db, $user, $auth, $module, $config;
$user->add_lang(array('viewtopic', 'viewforum'));
diff --git a/phpBB/modules/mcp/mcp_post.php b/phpBB/modules/mcp/mcp_post.php
index 9cb5b2cdae..b296c3626f 100644
--- a/phpBB/modules/mcp/mcp_post.php
+++ b/phpBB/modules/mcp/mcp_post.php
@@ -21,7 +21,7 @@ if (!defined('IN_PHPBB'))
*/
function mcp_post_details($id, $mode, $action)
{
- global $template, $db, $user, $auth, $cache, $config;
+ global $template, $db, $user, $auth, $config;
$user->add_lang('posting');
diff --git a/phpBB/modules/mcp/mcp_queue.php b/phpBB/modules/mcp/mcp_queue.php
index 96ac7accb1..eefeb08f3d 100644
--- a/phpBB/modules/mcp/mcp_queue.php
+++ b/phpBB/modules/mcp/mcp_queue.php
@@ -33,7 +33,7 @@ class mcp_queue
function main($id, $mode)
{
- global $auth, $db, $user, $template, $cache;
+ global $auth, $db, $user, $template;
global $config, $action;
include_once(PHPBB_ROOT_PATH . 'includes/functions_posting.' . PHP_EXT);
diff --git a/phpBB/modules/mcp/mcp_reports.php b/phpBB/modules/mcp/mcp_reports.php
index 63d145eb49..a86e156438 100644
--- a/phpBB/modules/mcp/mcp_reports.php
+++ b/phpBB/modules/mcp/mcp_reports.php
@@ -33,7 +33,7 @@ class mcp_reports
function main($id, $mode)
{
- global $auth, $db, $user, $template, $cache;
+ global $auth, $db, $user, $template;
global $config, $action;
include_once(PHPBB_ROOT_PATH . 'includes/functions_posting.' . PHP_EXT);
diff --git a/phpBB/modules/mcp/mcp_topic.php b/phpBB/modules/mcp/mcp_topic.php
index 4ab9e244e1..22675a8c84 100644
--- a/phpBB/modules/mcp/mcp_topic.php
+++ b/phpBB/modules/mcp/mcp_topic.php
@@ -21,7 +21,7 @@ if (!defined('IN_PHPBB'))
*/
function mcp_topic_view($id, $mode, $action)
{
- global $template, $db, $user, $auth, $cache, $config;
+ global $template, $db, $user, $auth, $config;
$url = append_sid(PHPBB_ROOT_PATH. 'mcp.' . PHP_EXT . '?' . extra_url());
diff --git a/phpBB/modules/ucp/ucp_groups.php b/phpBB/modules/ucp/ucp_groups.php
index 67e6fdb9ea..f8c676df5f 100644
--- a/phpBB/modules/ucp/ucp_groups.php
+++ b/phpBB/modules/ucp/ucp_groups.php
@@ -26,7 +26,7 @@ class ucp_groups
function main($id, $mode)
{
- global $db, $user, $auth, $cache, $template, $config;
+ global $db, $user, $auth, $template, $config;
$user->add_lang('groups');
@@ -612,7 +612,7 @@ 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);
+ phpbb::$acm->destroy_sql(GROUPS_TABLE);
$message = ($action == 'edit') ? 'GROUP_UPDATED' : 'GROUP_CREATED';
trigger_error($user->lang[$message] . $return_page);
diff --git a/phpBB/modules/ucp/ucp_pm_viewfolder.php b/phpBB/modules/ucp/ucp_pm_viewfolder.php
index a67b64d229..7024c1d318 100644
--- a/phpBB/modules/ucp/ucp_pm_viewfolder.php
+++ b/phpBB/modules/ucp/ucp_pm_viewfolder.php
@@ -22,7 +22,7 @@ if (!defined('IN_PHPBB'))
*/
function view_folder($id, $mode, $folder_id, $folder)
{
- global $user, $template, $auth, $db, $cache, $config;
+ global $user, $template, $auth, $db, $config;
$submit_export = phpbb_request::is_set_post('submit_export');
diff --git a/phpBB/modules/ucp/ucp_pm_viewmessage.php b/phpBB/modules/ucp/ucp_pm_viewmessage.php
index e6e34efbfa..cd183a1085 100644
--- a/phpBB/modules/ucp/ucp_pm_viewmessage.php
+++ b/phpBB/modules/ucp/ucp_pm_viewmessage.php
@@ -21,7 +21,7 @@ if (!defined('IN_PHPBB'))
*/
function view_message($id, $mode, $folder_id, $msg_id, $folder, $message_row)
{
- global $user, $template, $auth, $db, $cache, $config;
+ global $user, $template, $auth, $db, $config;
$user->add_lang(array('viewtopic', 'memberlist'));
@@ -249,7 +249,7 @@ function view_message($id, $mode, $folder_id, $msg_id, $folder, $message_row)
*/
function get_user_information($user_id, $user_row)
{
- global $db, $auth, $user, $cache, $config;
+ global $db, $auth, $user, $config;
if (!$user_id)
{