diff --git a/wp-includes/media.php b/wp-includes/media.php index f4e60d00d8..03e4cb0ac0 100644 --- a/wp-includes/media.php +++ b/wp-includes/media.php @@ -1288,7 +1288,7 @@ class WP_Embed { return apply_filters( 'embed_maybe_make_link', $output, $url ); } } -$wp_embed = new WP_Embed(); +$GLOBALS['wp_embed'] = new WP_Embed(); /** * Register an embed handler. This function should probably only be used for sites that do not support oEmbed. diff --git a/wp-includes/widgets.php b/wp-includes/widgets.php index b90ffd6753..084ccd9702 100644 --- a/wp-includes/widgets.php +++ b/wp-includes/widgets.php @@ -385,7 +385,7 @@ $_wp_sidebars_widgets = array(); /** * Private */ - $_wp_deprecated_widgets_callbacks = array( + $GLOBALS['_wp_deprecated_widgets_callbacks'] = array( 'wp_widget_pages', 'wp_widget_pages_control', 'wp_widget_calendar', diff --git a/wp-settings.php b/wp-settings.php index 06af3dd3ce..45bb8994d3 100644 --- a/wp-settings.php +++ b/wp-settings.php @@ -104,6 +104,7 @@ require( ABSPATH . WPINC . '/l10n.php' ); // Run the installer if WordPress is not installed. wp_not_installed(); + // Load most of WordPress. require( ABSPATH . WPINC . '/class-wp-walker.php' ); require( ABSPATH . WPINC . '/class-wp-ajax-response.php' ); @@ -249,7 +250,7 @@ $wp = new WP(); * @global object $wp_widget_factory * @since 2.8.0 */ -$wp_widget_factory = new WP_Widget_Factory(); +$GLOBALS['wp_widget_factory'] = new WP_Widget_Factory(); do_action( 'setup_theme' );