DataBase Set Up Tutorial

This tutorial is to help you set up your MySQL database using cpanel (if your host doesn't have cpanel then you need to contact them to ask them to set it up for you).

You should have a link on your cpanel to MySQL databases - click on that.

Find this section under Databases :

Insert your chosen database name and then click [Add Db] - call it whatever you like, I've called it dbname here. Keep it short because most servers will append your cpanel username to the front of your chosen database name ie cpn_dbname. After you've clicked [Add Db] you'll get to another screen which tells you that you've added it - click [Back] to return to the previous screen.

Now scroll to the middle where you find the users section :

Key in your database user name and password then click [Add User]. Again most servers will append your cpanel username to the front of your chosen database username ie cpn_dbusername. After you've clicked on [Add User] you'll get taken to another screen which confirms you've added it - click [Back] to return to the previous screen.

Now find this section on the screen :

Very important - Make sure the Priveleges [All] box is ticked, use the drop downs to add the right user to database then click on [Add User to Db]. Again you'll get taken to another screen which confirms you've added it - click [Back] to return to the previous screen.

If you've done everything right, you should get some code printed out at the top of the screen which looks like this :

For security reasons most will not show your password. You need to now use the bits in red to add your details to the parameters.php file.

Open your parameters.php file in Notepad or Wordpad and find this section and alter the portions highlighted in red :
$dbusername='cpn_dbusername';
$password='password';
$database='cpn_dbname';