From 88c1ab7c7469e5d4f1d358ef86eedc88a37fbc1d Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Fri, 18 Sep 2015 05:47:27 +0000 Subject: [PATCH] Customize: Fix live previewing of menu changes on subdirectory installs. Props adamsilverstein, westonruter. Fixes #33916. Built from https://develop.svn.wordpress.org/trunk@34278 git-svn-id: http://core.svn.wordpress.org/trunk@34242 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/class-wp-customize-nav-menus.php | 6 +----- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/wp-includes/class-wp-customize-nav-menus.php b/wp-includes/class-wp-customize-nav-menus.php index 2b667cec86..1d78e2f63c 100644 --- a/wp-includes/class-wp-customize-nav-menus.php +++ b/wp-includes/class-wp-customize-nav-menus.php @@ -934,7 +934,7 @@ final class WP_Customize_Nav_Menus { 'renderQueryVar' => self::RENDER_QUERY_VAR, 'renderNonceValue' => wp_create_nonce( self::RENDER_AJAX_ACTION ), 'renderNoncePostKey' => self::RENDER_NONCE_POST_KEY, - 'requestUri' => '/', + 'requestUri' => empty( $_SERVER['REQUEST_URI'] ) ? home_url( '/' ) : esc_url_raw( wp_unslash( $_SERVER['REQUEST_URI'] ) ), 'theme' => array( 'stylesheet' => $this->manager->get_stylesheet(), 'active' => $this->manager->is_theme_active(), @@ -943,10 +943,6 @@ final class WP_Customize_Nav_Menus { 'navMenuInstanceArgs' => $this->preview_nav_menu_instance_args, ); - if ( ! empty( $_SERVER['REQUEST_URI'] ) ) { - $exports['requestUri'] = esc_url_raw( home_url( wp_unslash( $_SERVER['REQUEST_URI'] ) ) ); - } - printf( '', wp_json_encode( $exports ) ); } diff --git a/wp-includes/version.php b/wp-includes/version.php index 5f9681521b..e7d3d051c6 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.4-alpha-34277'; +$wp_version = '4.4-alpha-34278'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.