• Please help
    I get the following message when establishing an msqyl database in my cpanel:
    Connection Strings
    Perl $dbh = DBI->connect(“DBI:mysql:patreed4_wp:localhost”,”patreed4_pj”,”<PASSWORD HERE>”);
    PHP $dbh=mysql_connect (“localhost”, “patreed4_pj”, “<PASSWORD HERE>”) or die (‘I cannot connect to the database because: ‘ . mysql_error());
    mysql_select_db (“patreed4_wp”);
    When connecting to my web page at http://www.gotanevnet.com/wordpress/wp-admin/install.php I get the following message:
    Error establishing a database connection! This probably means that the connection information in your wp-config.php file is incorrect. Double check it and try again.
    • Are you sure you have the correct user/password?
    • Are you sure that you have typed the correct hostname?
    • Are you sure that the database server is running?
    I also get the following on my main page:
    Forbidden
    You don’t have permission to access / on this server.
    Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
    Apache/1.3.31 Server at http://www.gotanevent.com Port 80
    I have read the forums regarding this error message but nothing has worked for me. Any help would be greatly appreciated.

Viewing 3 replies - 1 through 3 (of 3 total)
  • This is not actually an error caused by WordPress.
    The WordPress code is using a standard format to set up the communications between the php code, and the mysql database.
    Are you totally sure that you have done everything advised in all the other threads ?

    I’m getting the same database connection error. My config settings are correct. I have used mysql beofre setting up phpBB on my host with no problems. My database for WP is active, I can log into it with the UN & PW I’m using in the WP config in phpmyadmin. I don’t know what else to check.
    I have tried my database name as mysql.xenakes.com (which is the format for the databases in my phpBB installs) xenakes and xenakes.com. None of them work.

    I figured out my problem. It seems I was part of the 1%. My final settings were like this.
    // ** MySQL settings ** //
    define(‘DB_NAME’, ‘xenakes’); // The name of the database
    define(‘DB_USER’, ‘xxxxxxxxxxx’); // Your MySQL username
    define(‘DB_PASSWORD’, ‘xxxxxx’); // …and password
    define(‘DB_HOST’, ‘mysql.xenakes.com’); // 99% chance you won’t need to change this value
    I was thrown off because in my phpBB installs my DB_Name was in the DB_Host format. After this change everything worked fine.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Error establishing a database connection! – Please’ is closed to new replies.