mirror of
git://develop.git.wordpress.org/
synced 2025-02-25 00:52:55 +01:00
Admin: Restore the "Show advanced menu properties" checkboxes IDs.
These checkboxes are used on the Menus screen options and the Customizer Menus options. Their IDs were removed in [34991] but they're needed to get the checkboxes to be saved via AJAX. Also, avoids a useless AJAX call. Fixes #35112 for trunk. git-svn-id: https://develop.svn.wordpress.org/trunk@36137 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
7ce16f660e
commit
93e3093a0a
@ -1087,7 +1087,7 @@ final class WP_Screen {
|
|||||||
|
|
||||||
$id = "$column-hide";
|
$id = "$column-hide";
|
||||||
echo '<label>';
|
echo '<label>';
|
||||||
echo '<input class="hide-column-tog" name="' . $id . '" type="checkbox" value="' . $column . '"' . checked( ! in_array( $column, $hidden ), true, false ) . ' />';
|
echo '<input class="hide-column-tog" name="' . $id . '" type="checkbox" id="' . $id . '" value="' . $column . '"' . checked( ! in_array( $column, $hidden ), true, false ) . ' />';
|
||||||
echo "$title</label>\n";
|
echo "$title</label>\n";
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
@ -157,8 +157,15 @@ var postboxes;
|
|||||||
},
|
},
|
||||||
|
|
||||||
save_state : function(page) {
|
save_state : function(page) {
|
||||||
var closed = $('.postbox').filter('.closed').map(function() { return this.id; }).get().join(','),
|
var closed, hidden;
|
||||||
hidden = $('.postbox').filter(':hidden').map(function() { return this.id; }).get().join(',');
|
|
||||||
|
// Return on the nav-menus.php screen, see #35112.
|
||||||
|
if ( 'nav-menus' === page ) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
closed = $( '.postbox' ).filter( '.closed' ).map( function() { return this.id; } ).get().join( ',' );
|
||||||
|
hidden = $( '.postbox' ).filter( ':hidden' ).map( function() { return this.id; } ).get().join( ',' );
|
||||||
|
|
||||||
$.post(ajaxurl, {
|
$.post(ajaxurl, {
|
||||||
action: 'closed-postboxes',
|
action: 'closed-postboxes',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user