#35182 [Bgs]: Successfully loaded, but cannot use Mysqli functions/class
| From: | webmaster at mif dot it | Date: | Thu, 10 Nov 2005 13:42:06 +0000 |
| Subject: | #35182 [Bgs]: Successfully loaded, but cannot use Mysqli functions/class | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-87990@lists.php.net to get a copy of this message | ||
ID: 35182
User updated by: webmaster at mif dot it
Reported By: webmaster at mif dot it
Status: Bogus
Bug Type: MySQLi related
Operating System: Win XP Pro
PHP Version: 5.0.5
New Comment:
Thx, now it works properly, but some apps r really slow.
Previous Comments:
------------------------------------------------------------------------
[2005-11-10 14:35:43] johannes@php.net
You need to disable zendengine1 compatibility mode in your
php.ini for using PHP 5 OO stuff.
------------------------------------------------------------------------
[2005-11-10 14:31:47] webmaster at mif dot it
Editing
------------------------------------------------------------------------
[2005-11-10 14:31:10] webmaster at mif dot it
Improving text
------------------------------------------------------------------------
[2005-11-10 14:28:20] webmaster at mif dot it
Description:
------------
Cannot use Mysqli functions, without using references.
Reproduce code:
---------------
This code:
$db = mysqli_connect('localhost','Matteo','teo28273');
and this doesn't works:
$db = new mysqli('localhost','Matteo','teo28273');
This code:
$db =& mysqli_connect('localhost','Matteo','teo28273');
and this code works:
$db =& new mysqli('localhost','Matteo','teo28273');
Expected result:
----------------
The following code (and all mysqli functions) work properly:
$db = mysqli_connect('localhost','Matteo','teo28273'); or
$db = new mysqli('localhost','Matteo','teo28273');
Actual result:
--------------
Produces this error:
#Fatal error: Trying to clone an uncloneable object of class mysqli in
[***]\index.php on line 4
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=35182&edit=1