Support » Installing WordPress » Installation/upgrade issue

  • Resolved rdhill316


    I just decided to update my wordpress installation, so I downloaded the version linked to on the download page, and sent everything up to my site.

    I got the error: “
    Fatal error: Call to undefined function is_blog_installed() in /home/content/r/d/h/rdhill316/html/wordpress/wp-settings.php on line 140″

    I tried deleting everything & doing a fresh install, and got the same error.

    I can’t find anything in the forums on how to fix this.

    I did some checking and the function “is_blog_installed” is called in this block of code in wp-settings.php:

    if ( !is_blog_installed() && (strpos($_SERVER['PHP_SELF'], 'install.php') === false && !defined('WP_INSTALLING')) ) {
    	if (strpos($_SERVER['PHP_SELF'], 'wp-admin') !== false)
    		$link = 'install.php';
    		$link = 'wp-admin/install.php';
    	wp_die(sprintf("It doesn't look like you've installed WP yet. Try running <a href='%s'>install.php</a>.", $link));

    but a search of all files in the wordpress directory reveals no definition of the function.

    the older version of the wp-settings file had the block of code thusly:

    $db_check = $wpdb->get_var("SELECT option_value FROM $wpdb->options WHERE option_name = 'siteurl'");
    if ( !$db_check && (!strstr($_SERVER['PHP_SELF'], 'install.php') && !defined('WP_INSTALLING')) ) {
    	if ( strstr($_SERVER['PHP_SELF'], 'wp-admin') )
    		$link = 'install.php';
    		$link = 'wp-admin/install.php';
    	die(sprintf(__("It doesn't look like you've installed WP yet. Try running <a href='%s'>install.php</a>."), $link));

    Is the old method still valid so that I can change the code back?

    Or am I missing something?

    Any help is appreciated. Thanks!

Viewing 5 replies - 1 through 5 (of 5 total)
  • Did you run the update script. I believe if you try to login to wordpress it will ask you do update.

    Update script (wp-admin/upgrade.php)won’t run — same error.

    Neither will the install script (wp-admin/install.php); it also gives the same error.

    Any page that include()s wp-settings.php gives the same error, so I can’t even try to log in.

    The problem is that the function “is_blog_installed()” doesn’t seem to be defined anywhere.

    I’m going to try defining it myself using the old code as a guide. I’m pretty sure that will fix it; the only thing I’m unsure of is whether the method of checking if wordpress is installed based on querying the db to see if ‘siteurl’ exists is still valid. Guess I’ll find out. Time for a smoke test 🙂

    Well, I made my own definition of the function is_blog_installed(), just basically ripped the database checking from the old code, and got this:

    function is_blog_installed() {
    	$db_check = $wpdb->get_var("SELECT option_value FROM $wpdb->options WHERE option_name = 'siteurl'");
    	return $db_check;

    Which seemed to fix the problem … at least for that function. Now default-filters.php is calling a different undefined function, “add_filter().”

    I’m beginning to suspect that there is a missing file somewhere that contains the definitions for miscellaneous functions, or maybe an old version is mixed in with the current code (I’m using the code linked to from the download page,

    Can someone more familiar with the codebase please check the current downloadable files to make sure they are all from the same version?

    Or have I screwed up something glaringly obvious here during my install?


    When you uploaded your files did you use ftp and did you use Ascii mode if you didn’t use ascii mode then that is your problem reupload the files using ascii mode and see if that helped.

    So what was happening was this:
    My FTP client was cheerfully trying to send over files to the server as fast as possible. Sometimes it would send one before the connection for the previous file closed.

    Whenever that happened, the remote server said “too many conections open from this IP” — and closed the connection. So the file didn’t get sent.

    One of the unlucky files that didn’t get sent was the functions.php which defines the functions that were popping up in the errors.

    This file was particularly unlucky because it (apparently) got left out the first time I tried to upgrade, and again when I tried a fresh install.

    When I compared the contents of the wordpress directories on the server with my local machine, I said “Hey! theres a bunch of files missing!” Then I paid close attention to what was happening with the FTP transfer, and saw the problem in the logs.

    So I used a different FTP client, which was slower, but very thoroughly plodded its way through all the files. Problem solved!

    Needless to say, I’m going to switch FTP clients if I can’t find a way to throttle down the one I’ve got.


Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Installation/upgrade issue’ is closed to new replies.