Version 2.2.0 RC-1

This commit is contained in:
Neo committed 2025-12-19 00:22:37 -08:00
1 parent f73f8bff6d
commit 22f1b963ee
1034 files changed
+178610 -70897

No files matched your search

+118 -71
View File
@@ -2,27 +2,17 @@
/*
+--------------------------------------------------------------------------
| Invision Power Board 2.1.7
| Invision Power Board
| =============================================
| by Matthew Mecham
| (c) 2001 - 2005 Invision Power Services, Inc.
| (c) 2001 - 2006 Invision Power Services, Inc.
| http://www.invisionpower.com
| =============================================
| Web: http://www.invisionboard.com
| http://www.ibresource.ru/products/invisionpowerboard/
| Time: Tuesday 18th of July 2006 05:56:00 PM
| Release: 52f408a29988b02f45b5e6f4ba5af0ae
| Licence Info: http://www.invisionboard.com/?license
| http://www.ibresource.ru/license
+---------------------------------------------------------------------------
| INVISION POWER BOARD IS NOT FREE / OPEN SOURCE!
+---------------------------------------------------------------------------
| INVISION POWER BOARD ÍÅ ßÂËßÅÒÑß ÁÅÑÏËÀÒÍÛÌ ÏÐÎÃÐÀÌÌÍÛÌ ÎÁÅÑÏÅ×ÅÍÈÅÌ!
| Ïðàâà íà ÏÎ ïðèíàäëåæàò Invision Power Services
| Ïðàâà íà ïåðåâîä IBResource (http://www.ibresource.ru)
+---------------------------------------------------------------------------
| > $Date: 2005-10-10 14:08:54 +0100 (Mon, 10 Oct 2005) $
| > $Revision: 23 $
| > $Date: 2006-09-22 11:28:54 +0100 (Fri, 22 Sep 2006) $
| > $Revision: 567 $
| > $Author: matt $
+---------------------------------------------------------------------------
|
@@ -37,7 +27,7 @@
if ( ! defined( 'IN_ACP' ) )
{
print "<h1>Íåâåðíûé âõîä</h1> Ó Âàñ íåò äîñòóïà ê äèðåêòèâå ýòîãî ôàéëà. Åñëè Âû ïðîâîäèëè îáíîâëåíèÿ, óáåäèòåñü, ÷òî íå çàáûëè îáíîâèòü 'admin.php'.";
print "<h1>Incorrect access</h1>You cannot access this file directly. If you have recently upgraded, make sure you upgraded 'admin.php'.";
exit();
}
@@ -67,8 +57,9 @@ class ad_administration
// Require and RUN !! THERES A BOMB
//-----------------------------------------
$this->ipsclass->admin->page_detail = "Óïðàâëåíèå êåøåì ïîçâîëÿåò âàì ïðîñìàòðèâàòü ñîäåðæèìîå âàøåãî êåøà, à òàêæå è îáíîâëÿòü åãî.";
$this->ipsclass->admin->page_title = "Óïðàâëåíèå êåøåì";
$this->ipsclass->admin->page_detail = "The cache manager allows you to view the contents of your cache and update them.";
$this->ipsclass->admin->page_title = "Cache Manager";
$this->ipsclass->admin->nav[] = array( $this->ipsclass->form_code, 'Cache Manager' );
//-----------------------------------------
// Load skin
@@ -76,41 +67,31 @@ class ad_administration
$this->html = $this->ipsclass->acp_load_template('cp_skin_tools');
//-----------------------------------------
// Kill globals - globals bad, Homer good.
//-----------------------------------------
$tmp_in = array_merge( $_GET, $_POST, $_COOKIE );
foreach ( $tmp_in as $k => $v )
{
unset($$k);
}
//-----------------------------------------
// Map
//-----------------------------------------
$this->map = array( 'forum_cache' => 'Èíôîðìàöèÿ è äàííûå î âñåõ ôîðóìàõ',
'group_cache' => 'Èíôîðìàöèÿ è äàííûå î âñåõ ïîëüçîâàòåëüñêèõ ãðóïï',
'systemvars' => 'Ðàáî÷åå âðåìÿ ñèñòåìû',
'skin_id_cache' => 'Èíôîðìàöèÿ è äàííûå è ñòèëÿõ',
'moderators' => 'Èíôîðìàöèÿ è äàííûåõ î âñåõ ìîäåðàòîðõ',
'stats' => 'Ñòàòèñòèêà ôîðóìà, îáùåå êîë-âî ñîîáùåíèé è ò.ä.',
'ranks' => 'Èíôîðìàöèÿ îá ó÷åòíûõ çàïèñÿõ ïîëüçîâàòåëåé è èõ ñòàòóñàõ',
'profilefields' => 'Èíôîðìàöèÿ î äîïîëíèòåëüíûõ ïîëÿõ â ïðîôèëå',
'birthdays' => 'Äíè ðîæäåíèÿ ïîëüçîâàòåëåé',
'calendar' => 'Ïðèáëèæàþùèåñÿ êàëåíäàðíûå ñîáûòèÿ',
'multimod' => 'Èíôîðìàöèÿ è äàííûå î ìóëüòè-ìîäåðàöèè',
'bbcode' => "Èíôîðìàöèÿ è äàííûå î ñïåöèàëüíûõ ÁÁ êîäàõ",
'settings' => "Íàñòðîéêè ôîðóìà è ïåðåìåííûõ",
'emoticons' => 'Èíôîðìàöèÿ è äàííûå î ñìàéëèêàõ',
'badwords' => 'Èíôîðìàöèÿ è äàííûå î ôèëüòðå íåöåíçóðíûõ ñëîâ',
'languages' => 'Èíôîðìàöèÿ î ÿçûêîâûõ íàñòðîéêàõ',
'banfilters' => 'Çàáàíåííûå IP àäðåñà',
'attachtypes' => 'Èíôîðìàöèÿ î òèïàõ ïðèêðåïëÿåìûõ ôàéëîâ',
'announcements' => 'Êåø ñîîáùåíèé',
'components' => 'Âêëþ÷åííûå êîìïîíåíòû â âàøåì IPB',
$this->map = array( 'forum_cache' => 'All forum information and data',
'group_cache' => 'All member group infomation and data',
'systemvars' => 'System runtime variables',
'skin_id_cache' => 'Skin set information and data',
'moderators' => 'All moderator information and data',
'stats' => 'Board stats, such as total posts, etc',
'ranks' => 'Member titles and rank information',
'profilefields' => 'Custom profile field information',
'birthdays' => 'Members birthdays',
'calendar' => 'Forthcoming calendar events',
'calendars' => 'Calendars you have created in the calendar manager',
'multimod' => 'Multi-moderation information and data',
'bbcode' => "Custom BBCode information and data",
'settings' => "Board settings and variables",
'emoticons' => 'Emoticon information and data',
'badwords' => 'Bad Word Filters information and data',
'languages' => 'Language Set information',
'banfilters' => 'Banned IP addresses',
'attachtypes' => 'Attachment Types information',
'announcements' => 'Announcements cache',
'components' => 'Components enabled on your IPB',
);
//-----------------------------------------
@@ -159,7 +140,7 @@ class ad_administration
$id = intval( $this->ipsclass->input['id'] );
$cache_name = '';
$count = 0;
$img = '<img src="'.$this->ipsclass->skin_url.'/images/aff_tick_small.png" border="0" alt="-" /> ';
$img = '<img src="'.$this->ipsclass->skin_acp_url.'/images/aff_tick_small.png" border="0" alt="-" /> ';
//-----------------------------------------
// Get cache name
@@ -202,7 +183,7 @@ class ad_administration
{
if ( ! $this->ipsclass->input['cache'] )
{
$this->ipsclass->main_msg = "Íå îäèí ID íå âûáðàí, ïîâòîðèòå ïîïûòêó çàíîâî ";
$this->ipsclass->main_msg = "No ID was passed, please try again";
$this->cache_start();
}
@@ -247,7 +228,7 @@ class ad_administration
$this->ipsclass->update_forum_cache();
$this->ipsclass->main_msg = 'Êåø ôîðóìà îáíîâëåí';
$this->ipsclass->main_msg = 'Forum Cache Updated';
break;
//-----------------------------------------
@@ -270,7 +251,7 @@ class ad_administration
$this->ipsclass->update_cache( array( 'name' => 'group_cache', 'array' => 1, 'deletefirst' => 1 ) );
$this->ipsclass->main_msg = 'Êåø ãðóïï îáíîâëåí';
$this->ipsclass->main_msg = 'Group Cache Updated';
break;
//-----------------------------------------
@@ -284,6 +265,62 @@ class ad_administration
$this->ipsclass->cache['systemvars']['mail_queue'] = intval( $result['cnt'] );
if ($this->ipsclass->vars['load_limit'] > 0)
{
# @ supressor fixes warning in >4.3.2 with open_basedir restrictions
if ( @file_exists('/proc/loadavg') )
{
if ( $fh = @fopen( '/proc/loadavg', 'r' ) )
{
$data = @fread( $fh, 6 );
@fclose( $fh );
$load_avg = explode( " ", $data );
$this->ipsclass->server_load = trim($load_avg[0]);
}
}
else if( strstr( strtolower(PHP_OS), 'win' ) )
{
/*---------------------------------------------------------------
| typeperf is an exe program that is included with Win NT,
| XP Pro, and 2K3 Server. It can be installed on 2K from the
| 2K Resource kit. It will return the real time processor
| Percentage, but will take 1 second processing time to do so.
| This is why we shall cache it, and check only every 2 mins.
|
| Can also be obtained from COM, but it's extremely slow...
---------------------------------------------------------------*/
$serverstats = @shell_exec("typeperf \"Processor(_Total)\% Processor Time\" -sc 1");
if( $serverstats )
{
$server_reply = explode( "\n", str_replace( "\r", "", $serverstats ) );
$serverstats = array_slice( $server_reply, 2, 1 );
$statline = explode( ",", str_replace( '"', '', $serverstats[0] ) );
$this->ipsclass->server_load = round( $statline[1], 4 );
}
}
else
{
if ( $serverstats = @exec("uptime") )
{
preg_match( "/(?:averages)?\: ([0-9\.]+),[\s]+([0-9\.]+),[\s]+([0-9\.]+)/", $serverstats, $load );
$this->ipsclass->server_load = $load[1];
}
}
if( $this->ipsclass->server_load )
{
$this->ipsclass->cache['systemvars']['loadlimit'] = $this->ipsclass->server_load."-".time();
}
}
$this->ipsclass->update_cache( array( 'name' => 'systemvars', 'array' => 1, 'deletefirst' => 1 ) );
require_once( ROOT_PATH.'sources/lib/func_taskmanager.php' );
@@ -291,7 +328,7 @@ class ad_administration
$task->ipsclass =& $this->ipsclass;
$task->save_next_run_stamp();
$this->ipsclass->main_msg = 'Ïåðåìåííûå ñèñòåìû îáíîâëåíû';
$this->ipsclass->main_msg = 'System Variables Updated';
break;
//-----------------------------------------
@@ -304,7 +341,7 @@ class ad_administration
$admin->ipsclass =& $this->ipsclass;
$admin->_rebuild_skin_id_cache();
$this->ipsclass->main_msg = 'Êåø ñòèëÿ îáíîâëåí';
$this->ipsclass->main_msg = 'Skin ID Cache Updated';
break;
//-----------------------------------------
@@ -321,7 +358,7 @@ class ad_administration
$this->mod->rebuild_moderator_cache();
$this->ipsclass->main_msg = 'Ìîäåðàòîðû îáíîâëåíû';
$this->ipsclass->main_msg = 'Moderators Updated';
break;
//-----------------------------------------
@@ -333,7 +370,7 @@ class ad_administration
$this->ipsclass->main_msg = 'Ñòàòèñòèêà îáíîâëåíà';
$this->ipsclass->main_msg = 'Statistics Updated';
break;
//-----------------------------------------
@@ -362,7 +399,7 @@ class ad_administration
$this->ipsclass->update_cache( array( 'name' => 'ranks', 'array' => 1, 'deletefirst' => 1 ) );
$this->ipsclass->main_msg = 'Ñòàòóñû îáíîâëåíû';
$this->ipsclass->main_msg = 'Ranks Updated';
break;
//-----------------------------------------
@@ -384,7 +421,7 @@ class ad_administration
$this->ipsclass->update_cache( array( 'name' => 'profilefields', 'array' => 1, 'deletefirst' => 1 ) );
$this->ipsclass->main_msg = 'Äîï. ïîëÿ â ïðîôèëå îáíîâëåíû';
$this->ipsclass->main_msg = 'Profile Fields Updated';
break;
//-----------------------------------------
@@ -404,9 +441,19 @@ class ad_administration
$task->restrict_log = 1;
$task->run_task();
$this->ipsclass->main_msg = 'Êàëåíäàðíûå ñîáûòèÿ îáíîâëåíû';
$this->ipsclass->main_msg = 'Calendar Events Updated';
break;
case 'calendars':
require_once( ROOT_PATH.'sources/action_admin/calendars.php' );
$cal = new ad_calendars();
$cal->ipsclass =& $this->ipsclass;
$cal->calendars_rebuildcache();
$this->ipsclass->main_msg = 'Calendars Updated';
break;
//-----------------------------------------
// Birthdays
//-----------------------------------------
@@ -424,7 +471,7 @@ class ad_administration
$task->restrict_log = 1;
$task->run_task();
$this->ipsclass->main_msg = 'Äíè ðîæäåíèÿ îáíîâëåíû';
$this->ipsclass->main_msg = 'Birthdays Updated';
break;
//-----------------------------------------
@@ -450,7 +497,7 @@ class ad_administration
$this->ipsclass->update_cache( array( 'name' => 'multimod', 'array' => 1, 'deletefirst' => 1 ) );
$this->ipsclass->main_msg = 'Ìóëüòè-ìîäåðàöèÿ îáíîâëåíà';
$this->ipsclass->main_msg = 'Multi-Moderation Updated';
break;
//-----------------------------------------
@@ -465,7 +512,7 @@ class ad_administration
$this->bbcode->bbcode_rebuildcache();
$this->ipsclass->main_msg = 'ÁÁ êîäû îáíîâëåíû';
$this->ipsclass->main_msg = 'BBCode Updated';
break;
//-----------------------------------------
@@ -493,7 +540,7 @@ class ad_administration
$this->ipsclass->update_cache( array( 'name' => 'settings', 'array' => 1, 'deletefirst' => 1 ) );
$this->ipsclass->main_msg = 'Íàñòðîéêè îáíîâëåíû';
$this->ipsclass->main_msg = 'Settings Updated';
break;
//-----------------------------------------
@@ -508,7 +555,7 @@ class ad_administration
$this->emoticons->emoticon_rebuildcache();
$this->ipsclass->main_msg = 'Ñìàéëèêè îáíîâëåíû';
$this->ipsclass->main_msg = 'Emoticons Updated';
break;
//-----------------------------------------
@@ -523,7 +570,7 @@ class ad_administration
$this->banandbadword->badword_rebuildcache();
$this->ipsclass->main_msg = 'Ôèëüòð íåöåíçóðíûõ ñëîâ îáíîâëåí';
$this->ipsclass->main_msg = 'Badwords Updated';
break;
//-----------------------------------------
@@ -544,7 +591,7 @@ class ad_administration
$this->ipsclass->update_cache( array( 'name' => 'languages', 'array' => 1, 'deletefirst' => 1 ) );
$this->ipsclass->main_msg = 'ßçûêè îáíîâëåíû';
$this->ipsclass->main_msg = 'Languages Updated';
break;
//-----------------------------------------
@@ -559,7 +606,7 @@ class ad_administration
$this->banandbadword->ban_rebuildcache();
$this->ipsclass->main_msg = 'Ôèëüòð áàíà îáíîâëåí';
$this->ipsclass->main_msg = 'Banfilters Updated';
break;
//-----------------------------------------
@@ -579,7 +626,7 @@ class ad_administration
$this->ipsclass->update_cache( array( 'name' => 'attachtypes', 'array' => 1, 'deletefirst' => 1 ) );
$this->ipsclass->main_msg = 'Òèïû ïðèñîåäèíÿåìûõ ôàéëîâ îáíîâëåíû';
$this->ipsclass->main_msg = 'Attachment Types Updated';
break;
//-----------------------------------------
@@ -593,7 +640,7 @@ class ad_administration
$announcements->ipsclass =& $this->ipsclass;
$announcements->announce_recache();
$this->ipsclass->main_msg = 'Ñîîáùåíèé îáíîâëåíû';
$this->ipsclass->main_msg = 'Announcements Updated';
break;
//-----------------------------------------
@@ -608,11 +655,11 @@ class ad_administration
$this->components->components_rebuildcache();
$this->ipsclass->main_msg = 'Êîìïîíåíòû îáíîâëåíû';
$this->ipsclass->main_msg = 'Components Updated';
break;
default:
$this->ipsclass->main_msg = 'Íå÷åãî îáíîâëÿòü';
$this->ipsclass->main_msg = 'No valid cache was specified to update';
break;
}