|
From: FlorinCB <ory...@us...> - 2008-08-18 19:48:34
|
Update of /cvsroot/mxbb/core/includes/db In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv20652/db Modified Files: mssql.php mysql.php mysql4.php mysqli.php Log Message: not fixed yet Index: mysql.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/db/mysql.php,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** mysql.php 30 Jul 2008 13:32:52 -0000 1.17 --- mysql.php 18 Aug 2008 19:48:23 -0000 1.18 *************** *** 62,66 **** if (version_compare($this->mysql_version, '4.1.3', '>=')) { ! if (PORTAL_BACKEND === 'phpbb3') { @mysql_query("SET NAMES 'utf8'", $this->db_connect_id); --- 62,66 ---- if (version_compare($this->mysql_version, '4.1.3', '>=')) { ! if (UTF_STATUS === 'phpbb3') { @mysql_query("SET NAMES 'utf8'", $this->db_connect_id); Index: mysql4.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/db/mysql4.php,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** mysql4.php 30 Jul 2008 13:32:52 -0000 1.18 --- mysql4.php 18 Aug 2008 19:48:24 -0000 1.19 *************** *** 67,71 **** $this->sql_layer = 'mysql4'; ! if (PORTAL_BACKEND === 'phpbb3') { @mysql_query("SET NAMES 'utf8'", $this->db_connect_id); --- 67,71 ---- $this->sql_layer = 'mysql4'; ! if (UTF_STATUS === 'phpbb3') { @mysql_query("SET NAMES 'utf8'", $this->db_connect_id); Index: mysqli.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/db/mysqli.php,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** mysqli.php 30 Jul 2008 13:35:08 -0000 1.18 --- mysqli.php 18 Aug 2008 19:48:25 -0000 1.19 *************** *** 55,59 **** { // mysqli only supported by phpBB3 ! //if (PORTAL_BACKEND === 'phpbb3') //{ @mysqli_query($this->db_connect_id, "SET NAMES 'utf8'"); --- 55,59 ---- { // mysqli only supported by phpBB3 ! //if (UTF_STATUS === 'phpbb3') //{ @mysqli_query($this->db_connect_id, "SET NAMES 'utf8'"); Index: mssql.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/db/mssql.php,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** mssql.php 7 Mar 2008 00:59:02 -0000 1.15 --- mssql.php 18 Aug 2008 19:48:23 -0000 1.16 *************** *** 38,42 **** * Connect to server */ ! function sql_connect($sqlserver, $sqluser, $sqlpassword, $database, $port = false, $persistency = false) { $this->persistency = $persistency; --- 38,45 ---- * Connect to server */ ! /** ! * Connect to server ! */ ! function sql_connect($sqlserver, $sqluser, $sqlpassword, $database, $port = false, $persistency = false, $new_link = false) { $this->persistency = $persistency; *************** *** 45,49 **** $this->dbname = $database; ! $this->db_connect_id = ($this->persistency) ? @mssql_pconnect($this->server, $this->user, $sqlpassword) : @mssql_connect($this->server, $this->user, $sqlpassword); if ($this->db_connect_id && $this->dbname != '') --- 48,67 ---- $this->dbname = $database; ! if (UTF_STATUS === 'phpbb3') ! { ! @ini_set('mssql.charset', 'UTF-8'); ! // enforce strict mode on databases that support it ! } ! @ini_set('mssql.textlimit', 2147483647); ! @ini_set('mssql.textsize', 2147483647); ! ! if (version_compare(PHP_VERSION, '5.1.0', '>=') || (version_compare(PHP_VERSION, '5.0.0-dev', '<=') && version_compare(PHP_VERSION, '4.4.1', '>='))) ! { ! $this->db_connect_id = ($this->persistency) ? @mssql_pconnect($this->server, $this->user, $sqlpassword, $new_link) : @mssql_connect($this->server, $this->user, $sqlpassword, $new_link); ! } ! else ! { ! $this->db_connect_id = ($this->persistency) ? @mssql_pconnect($this->server, $this->user, $sqlpassword) : @mssql_connect($this->server, $this->user, $sqlpassword); ! } if ($this->db_connect_id && $this->dbname != '') |