Update WP and plugins
This commit is contained in:
parent
10a4713229
commit
1fb77fc4ff
864 changed files with 101724 additions and 78262 deletions
|
@ -45,7 +45,7 @@ wp_check_php_mysql_versions();
|
|||
|
||||
// Disable magic quotes at runtime. Magic quotes are added using wpdb later in wp-settings.php.
|
||||
@ini_set( 'magic_quotes_runtime', 0 );
|
||||
@ini_set( 'magic_quotes_sybase', 0 );
|
||||
@ini_set( 'magic_quotes_sybase', 0 );
|
||||
|
||||
// WordPress calculates offsets from UTC.
|
||||
date_default_timezone_set( 'UTC' );
|
||||
|
@ -95,7 +95,10 @@ wp_set_lang_dir();
|
|||
// Load early WordPress files.
|
||||
require( ABSPATH . WPINC . '/compat.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-list-util.php' );
|
||||
require( ABSPATH . WPINC . '/formatting.php' );
|
||||
require( ABSPATH . WPINC . '/meta.php' );
|
||||
require( ABSPATH . WPINC . '/functions.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-meta-query.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-matchesmapregex.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-error.php' );
|
||||
|
@ -128,8 +131,9 @@ if ( is_multisite() ) {
|
|||
register_shutdown_function( 'shutdown_action_hook' );
|
||||
|
||||
// Stop most of WordPress from being loaded if we just want the basics.
|
||||
if ( SHORTINIT )
|
||||
if ( SHORTINIT ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Load the L10n library.
|
||||
require_once( ABSPATH . WPINC . '/l10n.php' );
|
||||
|
@ -142,7 +146,6 @@ wp_not_installed();
|
|||
// Load most of WordPress.
|
||||
require( ABSPATH . WPINC . '/class-wp-walker.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-ajax-response.php' );
|
||||
require( ABSPATH . WPINC . '/formatting.php' );
|
||||
require( ABSPATH . WPINC . '/capabilities.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-roles.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-role.php' );
|
||||
|
@ -157,8 +160,6 @@ require( ABSPATH . WPINC . '/user.php' );
|
|||
require( ABSPATH . WPINC . '/class-wp-user-query.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-session-tokens.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-user-meta-session-tokens.php' );
|
||||
require( ABSPATH . WPINC . '/meta.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-meta-query.php' );
|
||||
require( ABSPATH . WPINC . '/class-wp-metadata-lazyloader.php' );
|
||||
require( ABSPATH . WPINC . '/general-template.php' );
|
||||
require( ABSPATH . WPINC . '/link-template.php' );
|
||||
|
@ -275,6 +276,15 @@ $GLOBALS['wp_plugin_paths'] = array();
|
|||
// Load must-use plugins.
|
||||
foreach ( wp_get_mu_plugins() as $mu_plugin ) {
|
||||
include_once( $mu_plugin );
|
||||
|
||||
/**
|
||||
* Fires once a single must-use plugin has loaded.
|
||||
*
|
||||
* @since 5.1.0
|
||||
*
|
||||
* @param string $mu_plugin Full path to the plugin's main file.
|
||||
*/
|
||||
do_action( 'mu_plugin_loaded', $mu_plugin );
|
||||
}
|
||||
unset( $mu_plugin );
|
||||
|
||||
|
@ -283,6 +293,15 @@ if ( is_multisite() ) {
|
|||
foreach ( wp_get_active_network_plugins() as $network_plugin ) {
|
||||
wp_register_plugin_realpath( $network_plugin );
|
||||
include_once( $network_plugin );
|
||||
|
||||
/**
|
||||
* Fires once a single network-activated plugin has loaded.
|
||||
*
|
||||
* @since 5.1.0
|
||||
*
|
||||
* @param string $network_plugin Full path to the plugin's main file.
|
||||
*/
|
||||
do_action( 'network_plugin_loaded', $network_plugin );
|
||||
}
|
||||
unset( $network_plugin );
|
||||
}
|
||||
|
@ -294,8 +313,9 @@ if ( is_multisite() ) {
|
|||
*/
|
||||
do_action( 'muplugins_loaded' );
|
||||
|
||||
if ( is_multisite() )
|
||||
ms_cookie_constants( );
|
||||
if ( is_multisite() ) {
|
||||
ms_cookie_constants();
|
||||
}
|
||||
|
||||
// Define constants after multisite is loaded.
|
||||
wp_cookie_constants();
|
||||
|
@ -320,6 +340,15 @@ register_theme_directory( get_theme_root() );
|
|||
foreach ( wp_get_active_and_valid_plugins() as $plugin ) {
|
||||
wp_register_plugin_realpath( $plugin );
|
||||
include_once( $plugin );
|
||||
|
||||
/**
|
||||
* Fires once a single activated plugin has loaded.
|
||||
*
|
||||
* @since 5.1.0
|
||||
*
|
||||
* @param string $plugin Full path to the plugin's main file.
|
||||
*/
|
||||
do_action( 'plugin_loaded', $plugin );
|
||||
}
|
||||
unset( $plugin );
|
||||
|
||||
|
@ -331,8 +360,9 @@ require( ABSPATH . WPINC . '/pluggable-deprecated.php' );
|
|||
wp_set_internal_encoding();
|
||||
|
||||
// Run wp_cache_postload() if object cache is enabled and the function exists.
|
||||
if ( WP_CACHE && function_exists( 'wp_cache_postload' ) )
|
||||
if ( WP_CACHE && function_exists( 'wp_cache_postload' ) ) {
|
||||
wp_cache_postload();
|
||||
}
|
||||
|
||||
/**
|
||||
* Fires once activated plugins have loaded.
|
||||
|
@ -358,6 +388,7 @@ do_action( 'sanitize_comment_cookies' );
|
|||
|
||||
/**
|
||||
* WordPress Query object
|
||||
*
|
||||
* @global WP_Query $wp_the_query
|
||||
* @since 2.0.0
|
||||
*/
|
||||
|
@ -366,6 +397,7 @@ $GLOBALS['wp_the_query'] = new WP_Query();
|
|||
/**
|
||||
* Holds the reference to @see $wp_the_query
|
||||
* Use this global for WordPress queries
|
||||
*
|
||||
* @global WP_Query $wp_query
|
||||
* @since 1.5.0
|
||||
*/
|
||||
|
@ -373,6 +405,7 @@ $GLOBALS['wp_query'] = $GLOBALS['wp_the_query'];
|
|||
|
||||
/**
|
||||
* Holds the WordPress Rewrite object for creating pretty URLs
|
||||
*
|
||||
* @global WP_Rewrite $wp_rewrite
|
||||
* @since 1.5.0
|
||||
*/
|
||||
|
@ -380,6 +413,7 @@ $GLOBALS['wp_rewrite'] = new WP_Rewrite();
|
|||
|
||||
/**
|
||||
* WordPress Object
|
||||
*
|
||||
* @global WP $wp
|
||||
* @since 2.0.0
|
||||
*/
|
||||
|
@ -387,6 +421,7 @@ $GLOBALS['wp'] = new WP();
|
|||
|
||||
/**
|
||||
* WordPress Widget Factory Object
|
||||
*
|
||||
* @global WP_Widget_Factory $wp_widget_factory
|
||||
* @since 2.8.0
|
||||
*/
|
||||
|
@ -394,6 +429,7 @@ $GLOBALS['wp_widget_factory'] = new WP_Widget_Factory();
|
|||
|
||||
/**
|
||||
* WordPress User Roles
|
||||
*
|
||||
* @global WP_Roles $wp_roles
|
||||
* @since 2.0.0
|
||||
*/
|
||||
|
@ -407,19 +443,21 @@ $GLOBALS['wp_roles'] = new WP_Roles();
|
|||
do_action( 'setup_theme' );
|
||||
|
||||
// Define the template related constants.
|
||||
wp_templating_constants( );
|
||||
wp_templating_constants();
|
||||
|
||||
// Load the default text localization domain.
|
||||
load_default_textdomain();
|
||||
|
||||
$locale = get_locale();
|
||||
$locale = get_locale();
|
||||
$locale_file = WP_LANG_DIR . "/$locale.php";
|
||||
if ( ( 0 === validate_file( $locale ) ) && is_readable( $locale_file ) )
|
||||
if ( ( 0 === validate_file( $locale ) ) && is_readable( $locale_file ) ) {
|
||||
require( $locale_file );
|
||||
}
|
||||
unset( $locale_file );
|
||||
|
||||
/**
|
||||
* WordPress Locale object for loading locale domain date and various strings.
|
||||
*
|
||||
* @global WP_Locale $wp_locale
|
||||
* @since 2.1.0
|
||||
*/
|
||||
|
@ -436,12 +474,12 @@ $GLOBALS['wp_locale_switcher'] = new WP_Locale_Switcher();
|
|||
$GLOBALS['wp_locale_switcher']->init();
|
||||
|
||||
// Load the functions for the active theme, for both parent and child theme if applicable.
|
||||
if ( ! wp_installing() || 'wp-activate.php' === $pagenow ) {
|
||||
if ( TEMPLATEPATH !== STYLESHEETPATH && file_exists( STYLESHEETPATH . '/functions.php' ) )
|
||||
include( STYLESHEETPATH . '/functions.php' );
|
||||
if ( file_exists( TEMPLATEPATH . '/functions.php' ) )
|
||||
include( TEMPLATEPATH . '/functions.php' );
|
||||
foreach ( wp_get_active_and_valid_themes() as $theme ) {
|
||||
if ( file_exists( $theme . '/functions.php' ) ) {
|
||||
include $theme . '/functions.php';
|
||||
}
|
||||
}
|
||||
unset( $theme );
|
||||
|
||||
/**
|
||||
* Fires after the theme is loaded.
|
||||
|
@ -472,7 +510,7 @@ if ( is_multisite() ) {
|
|||
require( $file );
|
||||
die();
|
||||
}
|
||||
unset($file);
|
||||
unset( $file );
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue