Make WordPress Core


Ignore:
Timestamp:
01/27/2016 05:54:39 PM (10 years ago)
Author:
westonruter
Message:

Customizer: Export nonce, theme, and url app settings in preview as exported in pane.

  • Introduce WP_Customize_Manager::get_nonces() to consolidate logic for retrieving nonces.
  • Export nonces centrally in wp.customize.settings.nonce with each request and update nav menus preview to utilize.
  • Send updated nonces to preview upon nonce-refresh.
  • Request full preview refresh if Nav Menu selective refresh request fails (e.g. due to bad nonce).
  • Update nav menus and widgets in Customizer to utilize customize_refresh_nonces for exporting nonces and keeping them up to date.

See #27355.
Fixes #35617.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-customize-widgets.php

    r35793 r36414  
    662662
    663663        $settings = array(
    664             'nonce'                => wp_create_nonce( 'update-widget' ),
    665664            'registeredSidebars'   => array_values( $wp_registered_sidebars ),
    666665            'registeredWidgets'    => $wp_registered_widgets,
Note: See TracChangeset for help on using the changeset viewer.