Make WordPress Core

Ticket #7997: 7997.2.diff

File 7997.2.diff, 1.7 KB (added by sivel, 17 years ago)

use wp-settings.php and add and fix comments of what we are doing

  • wp-load.php

     
    2626        /** The config file resides in ABSPATH */
    2727        require_once( ABSPATH . 'wp-config.php' );
    2828
    29 } elseif ( file_exists( dirname(ABSPATH) . '/wp-config.php' ) && ! file_exists( dirname(ABSPATH) . '/wp-load.php' ) ) {
     29} elseif ( file_exists( dirname(ABSPATH) . '/wp-config.php' ) && ! file_exists( dirname(ABSPATH) . '/wp-settings.php' ) ) {
    3030
    31         /** The config file resides one level below ABSPATH */
     31        /** The config file resides one level above ABSPATH but is not part of another install*/
    3232        require_once( dirname(ABSPATH) . '/wp-config.php' );
    3333
    3434} else {
  • wp-admin/setup-config.php

     
    4242if (file_exists('../wp-config.php'))
    4343        wp_die("<p>The file 'wp-config.php' already exists. If you need to reset any of the configuration items in this file, please delete it first. You may try <a href='install.php'>installing now</a>.</p>");
    4444
    45 // Check if wp-config.php exists above the root directory
    46 if (file_exists('../../wp-config.php') && ! file_exists('../../wp-load.php'))
     45// Check if wp-config.php exists above the root directory but is not part of another install
     46if (file_exists('../../wp-config.php') && ! file_exists('../../wp-settings.php'))
    4747        wp_die("<p>The file 'wp-config.php' already exists one level above your WordPress installation. If you need to reset any of the configuration items in this file, please delete it first. You may try <a href='install.php'>installing now</a>.</p>");
    4848
    4949if (isset($_GET['step']))