Make WordPress Core

Changeset 13327


Ignore:
Timestamp:
02/23/2010 09:44:27 AM (15 years ago)
Author:
nacin
Message:

Use sprintf() in hard-coded string. Use same comment and error code as other identical message. See #11644 props hakre

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/wp-db.php

    r13325 r13327  
    990990        $this->$dbhname = @mysql_connect( $details[ 'db_host' ], $details[ 'db_user' ], $details[ 'db_password' ] );
    991991        if (!$this->$dbhname ) {
    992             $this->bail(/*WP_I18N_DB_CONNECT_DB*/"
     992            $this->bail( sprintf( /*WP_I18N_DB_CONN_ERROR*/"
    993993<h1>Error establishing a database connection</h1>
    994 <p>This either means that the username and password information in your <code>wp-config.php</code> file is incorrect or we can't contact the database server at <code>{$details['db_host']}</code>. This could mean your host's database server is down.</p>
     994<p>This either means that the username and password information in your <code>wp-config.php</code> file is incorrect or we can't contact the database server at <code>%s</code>. This could mean your host's database server is down.</p>
    995995<ul>
    996996    <li>Are you sure you have the correct username and password?</li>
     
    999999</ul>
    10001000<p>If you're unsure what these terms mean you should probably contact your host. If you still need help you can always visit the <a href='http://wordpress.org/support/'>WordPress Support Forums</a>.</p>
    1001 "/*/WP_I18N_DB_CONNECT_DB*/);
     1001"/*/WP_I18N_DB_CONN_ERROR*/, $details['db_host'] ), 'db_connect_fail' );
    10021002        }
    10031003        $this->select( $details[ 'db_name' ], $this->$dbhname );
Note: See TracChangeset for help on using the changeset viewer.