Version 2.3.6

This commit is contained in:
Neo committed 2025-12-19 00:26:08 -08:00
1 parent a3bb603c96
commit 19b38c7c74
764 files changed
+143731 -118164

No files matched your search

+20 -97
View File
@@ -1,25 +1,16 @@
<?php
/*
+--------------------------------------------------------------------------
| Invision Power Board 2.2.2
| Invision Power Board INSTALLER
| ========================================
| by Matthew Mecham
| (c) 2001 - 2005 Invision Power Services, Inc.
| http://www.invisionpower.com
| =============================================
| Web: http://www.invisionboard.com
| http://www.ibresource.ru/products/invisionpowerboard/
| Time: Monday 05th of March 2007 10:10:55 PM
| Release: e3790216629e5a2aaf37070b32237f06
| 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)
/*
+--------------------------------------------------------------------------
| Invision Power Board
| =============================================
| by Matthew Mecham
| (c) 2001 - 2006 Invision Power Services, Inc.
| http://www.invisionpower.com
| =============================================
| Web: http://www.invisionboard.com
| Time: Tue, 01 Nov 2005 14:38:09 GMT
| Release: 68ff9281c6fdcce88910e08cec1045a3
| Licence Info: http://www.invisionboard.com/?license
+---------------------------------------------------------------------------
| > $Date: 2005-10-10 16:01:09 +0100 (Mon, 10 Oct 2005) $
| > $Revision: 5 $
@@ -341,7 +332,7 @@ class ipsclass {
// Char set
//-----------------------------------------
$this->vars['gb_char_set'] = $this->vars['gb_char_set'] ? $this->vars['gb_char_set'] : 'windows-1251';
$this->vars['gb_char_set'] = $this->vars['gb_char_set'] ? $this->vars['gb_char_set'] : 'iso-8859-1';
//-----------------------------------------
// PHP API
@@ -496,7 +487,7 @@ class ipsclass {
* @return void
*/
function init_db_connection( $db, $user, $pass, $host, $pre, $cp, $driver='mysql' )
function init_db_connection( $db, $user, $pass, $host, $pre, $driver='mysql' )
{
//-----------------------------------------
// INIT
@@ -512,8 +503,8 @@ class ipsclass {
{
$file = str_replace( '<%driver%>', $driver, INS_SQL_FILE );
}
$classname = "db_driver_".$driver;
$classname = "db_driver_".$driver;
$this->DB = new $classname;
@@ -521,8 +512,7 @@ class ipsclass {
$this->DB->obj['sql_user'] = $user;
$this->DB->obj['sql_pass'] = $pass;
$this->DB->obj['sql_host'] = $host;
$this->DB->obj['sql_tbl_prefix'] = $pre;
$this->DB->obj['mysql_codepage'] = $cp;
$this->DB->obj['sql_tbl_prefix'] = $pre;
$this->DB->obj['use_shutdown'] = 0;
if ( $file )
@@ -918,31 +908,11 @@ class ipsclass {
{
if ( $v['donow'] )
{
if ( $this->vars['sql_driver'] == 'mysql' )
{
$this->DB->query( "REPLACE INTO ".SQL_PREFIX."cache_store SET cs_key='{$v['name']}', cs_value='$value', cs_array=".intval($v['array']) );
}
else
{
$this->DB->simple_construct( array( 'delete' => 'cache_store', 'where' => "cs_key='{$v['name']}'" ) );
$this->DB->simple_exec();
$this->DB->do_insert( 'cache_store', array( 'cs_array' => intval($v['array']), 'cs_key' => $v['name'], 'cs_value' => $value ) );
}
$this->DB->do_replace_into( 'cache_store', array( 'cs_array' => intval($v['array']), 'cs_key' => $v['name'], 'cs_value' => $value ), array( 'cs_key' ) );
}
else
{
if ( $this->vars['sql_driver'] == 'mysql' )
{
$this->DB->query( "REPLACE INTO ".SQL_PREFIX."cache_store SET cs_key='{$v['name']}', cs_value='$value', cs_array=".intval($v['array']) );
}
else
{
$this->DB->simple_construct( array( 'delete' => 'cache_store', 'where' => "cs_key='{$v['name']}'" ) );
$this->DB->simple_shutdown_exec();
$this->DB->do_shutdown_insert( 'cache_store', array( 'cs_array' => intval($v['array']), 'cs_key' => $v['name'], 'cs_value' => $value ) );
}
$this->DB->do_shutdown_replace_into( 'cache_store', array( 'cs_array' => intval($v['array']), 'cs_key' => $v['name'], 'cs_value' => $value ), array( 'cs_key' ) );
}
}
else
@@ -1003,54 +973,7 @@ class ipsclass {
$this->DB->close_db();
}
/*-------------------------------------------------------------------------*/
// Convert string between char-sets
/*-------------------------------------------------------------------------*/
/**
* Convert a string between charsets
*
* @param string Input String
* @param string Current char set
* @param string Destination char set
* @return string Parsed string
* @since 2.1.0
*/
function txt_convert_charsets($t, $original_cset, $destination_cset="")
{
$original_cset = strtolower($original_cset);
$text = $t;
//-----------------------------------------
// Did we pass a destination?
//-----------------------------------------
$destination_cset = strtolower($destination_cset) ? strtolower($destination_cset) : strtolower($this->vars['gb_char_set']);
// echo $destination_cset; exit;
//-----------------------------------------
// Not the same?
//-----------------------------------------
if ( $destination_cset == $original_cset )
{
return $t;
}
//-----------------------------------------
// Do the convert
//-----------------------------------------
if ( ! is_object( $this->class_convert_charset ) )
{
require_once( INS_KERNEL_PATH.'/class_convert_charset.php' );
$this->class_convert_charset = new class_convert_charset();
}
$text = $this->class_convert_charset->convert_charset( $text, $original_cset, $destination_cset );
return $text ? $text : $t;
}
/*-------------------------------------------------------------------------*/
// txt_alphanumerical_clean
// ------------------