I've been trying to get a quick staging environment setup on GoDaddy all day.
By using die('foo')
I can tell that GoDaddy is able to reach all of my files (public/index.php
, craft/config/db.php
and general.php
). I have created two different databases and users to try to connect to. I am also using the hostname's generated by GoDaddy.
However, even with the correct db information and knowing for a fact that Craft is able to find my db.php
file, when I browser to mydomain.com/index.php?p=admin/install
I'm still receiving the following error:
Craft can’t connect to the database with the credentials in craft/config/db.php.
db.php
/**
* Database Configuration
*
* All of your system's database configuration settings go in here.
* You can see a list of the default settings in craft/app/etc/config/defaults/db.php
*/
// die('foo');
return array(
// The database server name or IP address. Usually this is 'localhost' or '127.0.0.1'.
'server' => 'dbhost',
// The name of the database to select.
'database' => 'dbname',
// The database username to connect with.
'user' => '***',
// The database password to connect with.
'password' => '***',
// The prefix to use when naming tables. This can be no more than 5 characters.
'tablePrefix' => 'craft',
);
user
andpassword
, and post the rest of yourdb.php
into your question. – Lindsey D♦ Oct 28 '16 at 19:36dbhost
anddbname
the actual values, or just placeholders? Obviously those won't work. :) – Lindsey D♦ Oct 28 '16 at 19:49localhost
on Godaddy. See Mark's answer here: craftcms.stackexchange.com/a/10543/5471 – Steven Thate Oct 28 '16 at 19:51