Ticket #35112: 35112.patch
File 35112.patch, 2.1 KB (added by , 5 years ago) |
---|
-
src/wp-admin/includes/class-wp-screen.php
998 998 * Filter whether to show the Screen Options submit button. 999 999 * 1000 1000 * @since 4.4.0 1001 * 1001 * 1002 1002 * @param bool $show_button Whether to show Screen Options submit button. 1003 1003 * Default false. 1004 1004 * @param WP_Screen $this Current WP_Screen instance. … … 1087 1087 1088 1088 $id = "$column-hide"; 1089 1089 echo '<label>'; 1090 echo '<input class="hide-column-tog" name="' . $id . '" type="checkbox" value="' . $column . '"' . checked( ! in_array( $column, $hidden ), true, false ) . ' />';1090 echo '<input class="hide-column-tog" name="' . $id . '" type="checkbox" id="' . $id . '" value="' . $column . '"' . checked( ! in_array( $column, $hidden ), true, false ) . ' />'; 1091 1091 echo "$title</label>\n"; 1092 1092 } 1093 1093 ?> -
src/wp-admin/js/postbox.js
50 50 this.page = page; 51 51 this.init( page, args ); 52 52 53 $handles.on( 'click.postboxes', 53 $handles.on( 'click.postboxes', this.handle_click ); 54 54 55 55 $('.postbox .hndle a').click( function(e) { 56 56 e.stopPropagation(); … … 157 157 }, 158 158 159 159 save_state : function(page) { 160 var closed = $('.postbox').filter('.closed').map(function() { return this.id; }).get().join(','), 161 hidden = $('.postbox').filter(':hidden').map(function() { return this.id; }).get().join(','); 160 var closed, hidden; 162 161 162 // Return on the nav-menus.php screen, see #35112. 163 if ( 'nav-menus' === page ) { 164 return; 165 } 166 167 closed = $( '.postbox' ).filter( '.closed' ).map( function() { return this.id; } ).get().join( ',' ); 168 hidden = $( '.postbox' ).filter( ':hidden' ).map( function() { return this.id; } ).get().join( ',' ); 169 163 170 $.post(ajaxurl, { 164 171 action: 'closed-postboxes', 165 172 closed: closed,