PHP Forums Archive

Database Configuration

Tags: mysql, database, configuration

Olaf posted on 2008-01-01 21:46:16 #

Since a few days there is some change for classes using a MySQL database:

In the past the the constant variables are located in the db_config file which is located (by default) in the folder where the class file is also located.
Because many users (including me) are using 2 or more classes in one project it's needed to use only one file with the database connection variables. The file db.php contains this vars now and is located (by default) in the folder classes (one above the root).

Comments / discussions

erickaf10 posted on 2009-08-06 22:14:31 #

Where is the file that comes in db.php include_once ($ _SERVER [ 'DOCUMENT_ROOT'].'/ classes / db.php'); as it concerns

Olaf posted on 2009-08-07 07:22:52 #

Quote from: erickaf10
"Where is the file that comes in db.php include_once ($ _SERVER [ 'DOCUMENT_ROOT'].'/ classes / db.php'); as it concerns"

check this post:
http://www.finalwebsites.com/forums/topic/where-dbphp#post-1250

erickaf10 posted on 2009-08-07 18:04:56 #

Thank you very much for resporder. Now if I work.