Ticket #51507: 51507-2.patch
File 51507-2.patch, 1.8 KB (added by , 15 months ago) |
---|
-
wp-load.php
36 36 error_reporting( E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR ); 37 37 } 38 38 39 if ( ! defined( 'SHORTINIT_WITHOUT_DB' ) ) { 40 define( 'SHORTINIT_WITHOUT_DB', false ); 41 } 42 39 43 /* 40 44 * If wp-config.php exists in the WordPress root, or if it exists in the root and wp-settings.php 41 45 * doesn't, load wp-config.php. The secondary check for wp-settings.php has the added benefit … … 54 58 /** The config file resides one level above ABSPATH but is not part of another installation */ 55 59 require_once dirname( ABSPATH ) . '/wp-config.php'; 56 60 61 } elseif (SHORTINIT_WITHOUT_DB && @file_exists( ABSPATH . 'wp-settings.php' ) ) { 62 63 /** If user set the constant, we include wp-settings, even though wp-config does not exist */ 64 require_once ABSPATH . 'wp-settings.php'; 65 57 66 } else { 58 67 59 68 // A config file doesn't exist. -
wp-settings.php
115 115 require ABSPATH . WPINC . '/class-wp.php'; 116 116 require ABSPATH . WPINC . '/class-wp-error.php'; 117 117 require ABSPATH . WPINC . '/pomo/mo.php'; 118 119 // Stop here if constant is set. This is useful when users include WP as a helper 120 // framework, to use its goodies (helper methods) without need of loading DB 121 if ( SHORTINIT_WITHOUT_DB ) { 122 return; 123 } 124 118 125 require ABSPATH . WPINC . '/l10n/class-wp-translation-controller.php'; 119 126 require ABSPATH . WPINC . '/l10n/class-wp-translations.php'; 120 127 require ABSPATH . WPINC . '/l10n/class-wp-translation-file.php';