How do i find MySQL host name and password for php forum?

nourgomaa

Registered
Oct 22, 2011
1
0
51
Mansourah, Ad Daqahliyah, Egypt, Egypt
cPanel Access Level
Website Owner
Hi there!

I am about creating new phpbb3 website. At first.. i am new at databases and SQL. I want to ask... in php setup step "Database settings" it requires me to fill "Database server hostname or DSN"

In vpanel i used to fill it with name like "sql1.xxxx.com", but here in cpanel i cannot find this or the password. I saw many threads like this and the answer was "localhost is fine!"

Where can i find "localhost"?, and how can i connect the database to the php forum through the localhost?

and the last thing that i cannot login into "WHM", i enter the username and the password correctly, and if i click on login it always refreshes the page.

Could anyone help me?

Sorry for lengthy and my bad knowledge about databases

Thanks in advance!
 
Last edited by a moderator:

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
43
348
somewhere over the rainbow
cPanel Access Level
Root Administrator
In order to get a working connection for a new installation of phpbb3, you'd first want to go to the cPanel account, click on MySQL Databases area there.

In that area, create a database. After you create the database, create a database user. After you create the database user, add the database user to the database.

Now, when you install phpbb3, use localhost for the hostname. You don't have to use anything else but the word localhost for that field. Next, use the database username and database username's password for the user to connect to the database. If the database name is required, enter the database name that you created as well.

For WHM, the username would be root with the root password if you are a root level user. If you are a reseller user, it would be your reseller username and password. If you aren't the root level user nor a reseller, you probably do not have WHM access. You would want to contact your hosting provider to find out your access level, since you may only have cPanel access.