Forums / General Questions / Unable to connect the database with new host.

Unable to connect the database with new host.

Locked

Views: 640

Results 1 to 2 of 2
This thread is locked. New replies are disabled.
9 Mar 2010, 3:29 PM
#1
wmorris avatar

wmorris

Totally Zenned

Join Date:
Aug 2007
Location:
Amarillo, Tx
Posts:
1,683
Plugin Contributions:
0

Unable to connect the database with new host.

I have just moved my store to a new host I am trying reconfigure my configure.php file.

Here is my database information:

// define our database connection

define('DB_TYPE', 'mysql');

define('DB_PREFIX', '');

define('DB_SERVER', 'localhost');

define('DB_SERVER_USERNAME', 'hkeaton_giftshop2');

define('DB_SERVER_PASSWORD', 'XXXXXXX');

define('DB_DATABASE', 'hkeaton_giftshop2');

define('USE_PCONNECT', 'false');

define('STORE_SESSIONS', 'db');

// for STORE_SESSIONS, use 'db' for best support, or '' for file-based storage

I think I am missing a DB Prefix or something.

9 Mar 2010, 4:11 PM
#2
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Unable to connect the database with new host.

If the name of your database is 'giftshop2' and your hosting account user name is 'hkeaton", and you created a DB user named 'giftshop2' that should be right. Otherwise, I'd guess you have the user name wrong.

Usually, hosts prepend the CPanel user name to the DB name, and to any DB user you set up in the DB section.