Return to step 1 on custom-header.php if not POST data is sent. Good for if step=2 or 3 is in the URL and the page is refreshed (otherwise a nonce check fails). see #20249.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20211 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
4bfef892c7
commit
28f421fa6f
|
@ -894,7 +894,7 @@ wp_nonce_field( 'custom-header-options', '_wpnonce-custom-header-options' ); ?>
|
||||||
if ( ! current_user_can('edit_theme_options') )
|
if ( ! current_user_can('edit_theme_options') )
|
||||||
wp_die(__('You do not have permission to customize headers.'));
|
wp_die(__('You do not have permission to customize headers.'));
|
||||||
$step = $this->step();
|
$step = $this->step();
|
||||||
if ( 1 == $step )
|
if ( 1 == $step || ! $_POST )
|
||||||
$this->step_1();
|
$this->step_1();
|
||||||
elseif ( 2 == $step )
|
elseif ( 2 == $step )
|
||||||
$this->step_2();
|
$this->step_2();
|
||||||
|
|
Loading…
Reference in New Issue