Error DB connection
-
Hello all,
I’ve got an Apache with PHP (supported versions – PHP 5.2.17, Apache 2.2.22 – and working properly). I downloaded wordpress 3.3.2 version, extracted, copy under Apache.
I filed in properly the ‘wp-config.php’.
I tried open https://localhost/wordpress/wp-admin/install.php and I got an error message:
————————————————
Error establishing a database connectionThis either means that the username and password information in your wp-config.php file is incorrect or we can’t contact the database server at 127.0.0.1:3306. This could mean your host’s database server is down.
Are you sure you have the correct username and password?
Are you sure that you have typed the correct hostname?
Are you sure that the database server is running?
————————————————-
I’m sure the mysql is run, I can connect to wordperss db.
I wrote a sort php code:<?php $kapcsolat = mysql_connect ( "localhost", "wordpress", "VerySecretPass"); if (! $kapcsolat) { die ("mysql connect error"); } else { echo "mysql connect OK"; } ?>
I tried to insert in ‘wp-db.php’ file like:
————————————————function db_connect() { $this->is_mysql = true; if ( WP_DEBUG ) { $this->dbh = mysql_connect( $this->dbhost, $this->dbuser, $this->dbpassword, true ); } else { $this->dbh = mysql_connect( "localhost", "wordpress", "VerySecurePass", true ); }
————————————————
and it works. The install page appears correctly but I didn’t do anything. I don’t know what the basic problem is and what will happen, if I follow the install.
Could anyone help me?Thank you,
jupiter2005ster
- The topic ‘Error DB connection’ is closed to new replies.