• I keep getting “Your PHP installation appears to be missing the MySQL which is required for WordPress” no matter what I do. I found that this error message comes from wp-settings.php line 54. Where in the world am I supposed to get this file seeing it did not come in the download? I downloaded both the zip and the tat.gz versions, and it just ain’t there.

    if ( !extension_loaded('mysql') && !file_exists(ABSPATH . 'wp-content/db.php') )
    	die( 'Your PHP installation appears to be missing the MySQL which is required for WordPress.' );

    Now, I also removed the !file_exists(ABSPATH.’wp-cointent/db.php) from the if-statement, and still got the error, so apparently beyond the file being missing, mysql extension is not loaded. HOWEVER, I already uncommented extension=php_mysql.dll and
    extension=php_mysqli.dll in my php.ini and I created the c:\program files\php\ext directory and placed those dlls files in it along with libmysql.dll which i placed both in the ext and the root php installation directory. I have the mysql 5.xx server running and could connect with JSPs inside Tomcat (which I uninstaller before installing Apache HTTP server, btw).

Viewing 4 replies - 1 through 4 (of 4 total)
  • I have no clue how to fix it but I have the same error.

    Did either of you make any progress on this? I think I am in the same boat as the OP. However I have not ried this yet:

    “I created the c:\program files\php\ext directory and placed those dlls files in it along with libmysql.dll which i placed both in the ext and the root php installation directory.”

    Please post a solution if there is one.

    Regards,

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.remarpro.com Admin

    There is no wp-content/db.php file. That check is to allow plugins to rewrite WordPress to use alternative database systems instead of mySQL. Notice the “else” line after it that loads wp-includes/wp-db.php instead? That’s what normally loads, and it requires mySQL.

    If you get the “Your PHP installation appears to be missing the MySQL which is required for WordPress.” message, then your PHP is configured incorrectly and the mysql extension is not loading.

    Otto42 – This is not a PHP config problem – the !file_exists line is followed by die() (lower down in the file than the bit you mentioned).

    Admins – if the db.php file is not there to start with, why is it checked for in the install script? The check || die appears to break the install, if you take it out the install continues on fine.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘wp-content/db.php missing?’ is closed to new replies.