The connection of mysql database to server using object oriented concept, I uses these files:
<?php
- connection.php
- mysql.php
- index.php
So, Now let's start:
First of all create a root_folder that will contains all of files says: eshop
Now open your favorite text-editor like as Adobe Dreamweaver and create a php file names connection.php and save it in our root folder as eshop.
connection.php
<?php
define( 'DB_SERVER' , 'localhost' );
define( 'DB_USER' , 'root' );
define( 'DB_PASSWORD' , '' );
define( 'DB_NAME' , 'eshop_db' );
?>
?>