Version 3.2.3
This commit is contained in:
1 parent
ae5c01cc78
commit
78706903a2
2641 files changed
+228363
-201264
No files matched your search
@@ -3,19 +3,19 @@
|
||||
/**
|
||||
* <pre>
|
||||
* Invision Power Services
|
||||
* IP.Board v3.1.4
|
||||
* IP.Board v3.2.3
|
||||
* MySQL Database Driver :: MySQLi client
|
||||
* Last Updated: $Date: 2010-10-06 12:04:54 -0400 (Wed, 06 Oct 2010) $
|
||||
* Last Updated: $Date: 2011-08-12 11:44:48 -0400 (Fri, 12 Aug 2011) $
|
||||
* </pre>
|
||||
*
|
||||
* @author $Author: mmecham $
|
||||
* @author $Author: mark $
|
||||
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
|
||||
* @license http://www.invisionpower.com/community/board/license.html
|
||||
* @license This is NULLED!
|
||||
* @package IP.Board
|
||||
* @subpackage Kernel
|
||||
* @link http://www.invisionpower.com
|
||||
* @link http://hatynka.in
|
||||
* @since Monday 28th February 2005 16:46
|
||||
* @version $Revision: 473 $
|
||||
* @version $Revision: 9390 $
|
||||
*/
|
||||
|
||||
class db_driver_mysql extends db_main_mysql implements interfaceDb
|
||||
@@ -23,16 +23,16 @@ class db_driver_mysql extends db_main_mysql implements interfaceDb
|
||||
/**
|
||||
* Connection failed flag
|
||||
*
|
||||
* @access private
|
||||
* @access protected
|
||||
* @var boolean Connection failed
|
||||
*/
|
||||
private $connect_failed = false;
|
||||
protected $connect_failed = false;
|
||||
|
||||
/**
|
||||
* constructor
|
||||
*
|
||||
* @access public
|
||||
* @return void
|
||||
* @return @e void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
@@ -80,23 +80,57 @@ class db_driver_mysql extends db_main_mysql implements interfaceDb
|
||||
$this->obj['sql_host'] = $host;
|
||||
$this->obj['sql_port'] = intval( $port );
|
||||
}
|
||||
|
||||
if( $this->obj['sql_port'] )
|
||||
{
|
||||
$this->connection_id = @mysqli_connect( $this->obj['sql_host'] ,
|
||||
$this->obj['sql_user'] ,
|
||||
$this->obj['sql_pass'],
|
||||
$this->obj['sql_database'],
|
||||
$this->obj['sql_port']
|
||||
);
|
||||
|
||||
/* Persistent connection */
|
||||
if( $this->obj['persistent'] )
|
||||
{
|
||||
$this->obj['sql_host'] = 'p:' . $this->obj['sql_host'];
|
||||
}
|
||||
|
||||
/* Use socket if specified */
|
||||
if( $this->obj['sql_socket'] )
|
||||
{
|
||||
if( $this->obj['sql_port'] )
|
||||
{
|
||||
$this->connection_id = @mysqli_connect( $this->obj['sql_host'],
|
||||
$this->obj['sql_user'],
|
||||
$this->obj['sql_pass'],
|
||||
$this->obj['sql_database'],
|
||||
$this->obj['sql_port'],
|
||||
$this->obj['sql_socket']
|
||||
);
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->connection_id = @mysqli_connect( $this->obj['sql_host'],
|
||||
$this->obj['sql_user'],
|
||||
$this->obj['sql_pass'],
|
||||
$this->obj['sql_database'],
|
||||
null,
|
||||
$this->obj['sql_socket']
|
||||
);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->connection_id = @mysqli_connect( $this->obj['sql_host'] ,
|
||||
$this->obj['sql_user'] ,
|
||||
$this->obj['sql_pass'],
|
||||
$this->obj['sql_database']
|
||||
);
|
||||
if( $this->obj['sql_port'] )
|
||||
{
|
||||
$this->connection_id = @mysqli_connect( $this->obj['sql_host'],
|
||||
$this->obj['sql_user'],
|
||||
$this->obj['sql_pass'],
|
||||
$this->obj['sql_database'],
|
||||
$this->obj['sql_port']
|
||||
);
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->connection_id = @mysqli_connect( $this->obj['sql_host'],
|
||||
$this->obj['sql_user'],
|
||||
$this->obj['sql_pass'],
|
||||
$this->obj['sql_database']
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if ( ! $this->connection_id )
|
||||
@@ -167,7 +201,7 @@ class db_driver_mysql extends db_main_mysql implements interfaceDb
|
||||
// Change the table prefix if needed
|
||||
//-----------------------------------------
|
||||
|
||||
if ( $this->no_prefix_convert )
|
||||
/*if ( $this->no_prefix_convert )
|
||||
{
|
||||
$bypass = 1;
|
||||
}
|
||||
@@ -178,7 +212,7 @@ class db_driver_mysql extends db_main_mysql implements interfaceDb
|
||||
{
|
||||
//$the_query = preg_replace("/\sibf_(\S+?)([\s\.,]|$)/", " ".$this->obj['sql_tbl_prefix']."\\1\\2", $the_query);
|
||||
}
|
||||
}
|
||||
}*/
|
||||
|
||||
//-----------------------------------------
|
||||
// Debug?
|
||||
@@ -233,7 +267,7 @@ class db_driver_mysql extends db_main_mysql implements interfaceDb
|
||||
// Reset array...
|
||||
//-----------------------------------------
|
||||
|
||||
$this->force_data_type = array();
|
||||
$this->resetDataTypes();
|
||||
$this->allow_sub_select = false;
|
||||
|
||||
if (! $this->query_id )
|
||||
@@ -270,7 +304,7 @@ class db_driver_mysql extends db_main_mysql implements interfaceDb
|
||||
$_data .= "\n|Extra: ". $array['Extra'];
|
||||
//$_data .= "\n+------------------------------------------------------------------------------+";
|
||||
|
||||
if ( ( $this->obj['use_bad_log'] AND $this->obj['bad_log'] ) AND stristr( $array['Extra'], 'filesort' ) OR stristr( $array['Extra'], 'temporary' ) )
|
||||
if ( ( $this->obj['use_bad_log'] AND $this->obj['bad_log'] ) AND ( stristr( $array['Extra'], 'filesort' ) OR stristr( $array['Extra'], 'temporary' ) ) )
|
||||
{
|
||||
$this->writeDebugLog( $the_query, $_data, $endtime, $this->obj['bad_log'], TRUE );
|
||||
}
|
||||
@@ -442,7 +476,7 @@ class db_driver_mysql extends db_main_mysql implements interfaceDb
|
||||
*
|
||||
* @access public
|
||||
* @param resource [Optional] Query id
|
||||
* @return void
|
||||
* @return @e void
|
||||
*/
|
||||
public function freeResult( $query_id=null )
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user