Make WordPress Core

Opened 9 years ago

Closed 9 years ago

#3883 closed defect (bug) (fixed)

PHP Fatal error: Call to undefined function is_wp_error() in /wp-includes/functions.php on line 1299 w/ patch

Reported by: tacker Owned by:
Milestone: 2.2 Priority: high
Severity: normal Version: 2.2
Component: General Keywords:
Focuses: Cc:


Happens if you access a fresh wp installation.


  • wp-includes/functions.php

    56function mysql2date($dateformatstring, $mysqlstring, $translate = true) { 
    67       global $wp_locale; 

Change History (5)

#1 @tacker
9 years ago

My first fix breaks other stuff.

This works:

  • wp-blog-header.php

    55       if ( strstr( $_SERVER['PHP_SELF'], 'wp-admin') ) $path = ''; 
    66       else $path = 'wp-admin/'; 
     8  require_once( dirname(__FILE__) . '/wp-includes/classes.php'); 
    89  require_once( dirname(__FILE__) . '/wp-includes/functions.php'); 
    910  wp_die("There doesn't seem to be a <code>wp-config.php</code> file. I need this before we can get started. Need more help? <a href='http://codex.wordpress.org/Editing_wp-config.php'>We got it</a>. You can <a href='{$path}setup-config.php'>create a <code>wp-config.php</code> file through a web interface</a>, but this doesn't work for all server setups. The safest way is to manually create the file.", "WordPress &rsaquo; Error"); 

#2 @foolswisdom
9 years ago

  • Milestone set to 2.2

Thanks for the patch!

What version are you running including svn revision? What server environment?

Would you attach patches instead of posting inline (include the project's path structure in your patch)?

#3 @ryan
9 years ago

Should already be fixed by [4926]

#4 @ryan
9 years ago

Oops, nevermind. This is a different case.

#5 @ryan
9 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [4973]) Fix wp_die() includes when bailing out in the blog header. Props tacker. fixes #3883

Note: See TracTickets for help on using tickets.