Allow for plugins to kick in before everything if define in wp-config

git-svn-id: http://svn.automattic.com/wordpress/trunk@2342 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
saxmatt 2005-02-15 00:46:58 +00:00
parent 067e48e161
commit 70a449d8d8
1 changed files with 11 additions and 1 deletions

View File

@ -31,6 +31,10 @@ timer_start();
// Change to E_ALL for development/debugging
error_reporting(E_ALL ^ E_NOTICE);
// For an advanced caching plugin to use, static because you would only want one
if ( defined('WP_CACHE') )
require (ABSPATH . 'wp-content/advanced-cache.php');
define('WPINC', 'wp-includes');
require_once (ABSPATH . WPINC . '/wp-db.php');
@ -89,7 +93,6 @@ require (ABSPATH . WPINC . '/kses.php');
require (ABSPATH . WPINC . '/version.php');
if (!strstr($_SERVER['PHP_SELF'], 'install.php') && !strstr($_SERVER['PHP_SELF'], 'wp-admin/import')) :
// Used to guarantee unique hash cookies
$cookiehash = md5(get_settings('siteurl')); // Remove in 1.4
define('COOKIEHASH', $cookiehash);
@ -97,6 +100,8 @@ endif;
require (ABSPATH . WPINC . '/vars.php');
do_action('core_files_loaded');
// Check for hacks file if the option is enabled
if (get_settings('hack_file')) {
if (file_exists(ABSPATH . '/my-hacks.php'))
@ -111,6 +116,11 @@ if ( get_settings('active_plugins') ) {
}
}
if ( defined('WP_CACHE') && function_exists('wp_cache_postload') )
wp_cache_postload();
do_action('plugins_loaded');
define('TEMPLATEPATH', get_template_directory());
// Load the default text localization domain.