NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
[resolved] extending mysqli


Joined: 01 Jun 2007
Posts: 3
Reply with quote
I'm trying to debug part of a php application I'm working on. The database class that I'm using extends mysqli. However when I run the debugger it runs up to the point where the class is defined and then give the following error:

Error:E_ERROR Class 'mysqli' not found at database.php line 17.

I have the projects mapping set to using the SRV webserver. I'm pretty sure the debugger runs in that environment as well. As I didn't install the DBG anywhere else. Is there something I'm doing wrong or does the SRV server not have mysqli?

I know there is nothing wrong with the custom class as the application runs fine with it.
View user's profileFind all posts by fosterinteractiveSend private message


Joined: 01 Jun 2007
Posts: 3
Reply with quote
So to further this problem, I did a case example.
the following code will cause the error in my previous post

Code:

<?php
/**
* @desc
*
*
*/
  class MyException extends Exception
  {
     function __construct()
     {
        parent::__construct();
     }
  }
 
  class mydB extends mysqli
  {
     function __construct(){
 
     }
  }
?>


As soon as the debugger gets to "class mydB extends myslqi" it causes the error. Is there some reason that Exception is a available for extension in the PhpED debugger while mysqli is not?
[/code]
View user's profileFind all posts by fosterinteractiveSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
Quote:
Error:E_ERROR Class 'mysqli' not found at database.php line 17.

Once you use mysqli class defined in mysqli php extension, why not to enable it in php.ini? Just to get it working Smile

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 01 Jun 2007
Posts: 3
Reply with quote
I'm guessing I have to add the extension and all of its settings into PHPEd's php.ini file.
View user's profileFind all posts by fosterinteractiveSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
Settings are probably already there as well as extension. You only need to uncomment it Smile

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website
[resolved] extending mysqli
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic