Jump to content

database connection class


sunilvadranapu

Recommended Posts

Hi,

  I want to write a class for database connection to mySQL. could any one help in sharing their ideas:

  my class is like this:

 

  variables:

 

Host                DB servername

Database          DB name

User                  DB username

Password          DB password

Connection_id    holds the connection state(fail/success)

Errno 

ErrorString

 

Functions:

ConnectDB ();     

queryDB();

fetchResult();

totRows();

conClose();

 

am i need to add any more methods

 

Link to comment
https://forums.phpfreaks.com/topic/89366-database-connection-class/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.