Make WordPress Core

Changeset 31420


Ignore:
Timestamp:
02/11/2015 08:56:21 PM (10 years ago)
Author:
ocean90
Message:

Widgets: Add return param for widgets admin page to the "Manage in Customizer" link.

props tywayne.
fixes #30888.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/widgets.php

    r31200 r31420  
    317317        printf(
    318318            ' <a class="add-new-h2 hide-if-no-customize" href="%1$s">%2$s</a>',
    319             admin_url( 'customize.php?autofocus[panel]=widgets' ),
     319            esc_url( add_query_arg(
     320                array(
     321                    array( 'autofocus' => array( 'panel' => 'widgets' ) ),
     322                    'return' => urlencode( wp_unslash( $_SERVER['REQUEST_URI'] ) )
     323                ),
     324                admin_url( 'customize.php' )
     325            ) ),
    320326            __( 'Manage in Customizer' )
    321327        );
Note: See TracChangeset for help on using the changeset viewer.