As I said before , in order to setup a script on your website like wordpress , php forums , contact forms scripts , you will definitely need to create a MySQL database first in order to install these scripts on your website , so it is a very important step , that you will use every time you are going to setup a new script .
So Let’s know how to create MySQL database , and then save your new MySQL database information because you will need this information later when you are installing any script .
Before starting the lesson , you must know that every script has it’s own database , so you can NOT create one database for more than one script , or you may fall in trouble .
so every time you are going to upload and install a new script , come here and follow the instructions , unless you’ve become a professional and do not need any resources
.
Creating MySQL database is consist of 3 steps .
1 ) Creating a database .
2) Creating username and password .
3) Adding your username to your database .
Now login to your Cpanel .
Search For ” MySQL Databases ” and click on it .
1 ) Creating a database
In front of ” New Database ” , put your desired database name ( you can write your database without any Restrictions , but do not make it so easy or so relevant to the script you are going to upload so that you are safe from being hacked or your database stolen )
Say I’m going to upload wordpress script , so I will create a database with the name of : wpbas
Then click on create database .
click ” Go back ” .
Now you have created a database , but it is not enough to complete the installing process of any script , you must create a username and password for the database you have just created , and then connecting them each other .
2) Creating username and password
Scroll down , you will find MySQL Users title , under it you will find New user , now write any disired username and password , they are like database name , you can write anything without any Restrictions .
Say I’m going to create a username : wpmyuser
and password : 123456 ( you can generate a random password by clicking on ” Generate password “ )
Then Click on ” create user ” .
( you will noticed that your cpanel password is added before your submitted database name , this is happen whenever you create a new database as well as creating a username , remember that your database name will be all the phrase not only after the underscore . i.e : cpanelusername_wpbas )
Click on ” Go back ” .
Now one more step , is to connect or add the username to the database .
3) Adding your username to your database .
Scroll Down , you will find ” Add User To Database ” Title , beneath it you will find two drop menus , one is for your databases and the second for your usernames .
Choose the database we have just created ( wpbas ) and the username we have just created too ( wpmyuser ) .
Then Click ” Submit ” .
Now you will see lot of radio buttons , ignore them all , just check the option ” ALL PRIVILEGES ” , and you will notice that all radio buttons are checked , if so then click on ” Make Changes ” .
Click on ” Go back ” .
After clicking on Go back you will go back to the page that you created database and username from , but now scroll down little , you will see something like that :
The database and username you have just created and connecting them each other will be listed in this table , you must see the database name in the left column , and the username added to it in the third column .
If that not appear to you , you probably did something wrong , maybe you forget adding the username to the database ( last step ) , just go back and follow up the instructions again .
Important Step :
Now go to your desktop and create a new text file , rename it to ” database information ” .
write down the following :
database name :
database username :
password :
Leave this text file open .
Now Go back to the the table that database and username listed in it , and then copy your database name and username , and past them in the text file .
So that the text file will be like that :
Now save this text file , and store it on your computer , as we will need this information of your database name , username and password when we are installing any script , so we will reopen it again in the ” installing wordpress tutorial ” , so that everything will be ready .
To Read the rest of Cpanel Lessons , go to : How To Use Cpanel To Control Your Website Easily .


















2 Responses to “How to create MySQL databases in Cpanel”