Simple Page Sidebars - Version 1.1.6

Version Description

  • Prevent quick edit nonces from being submitted when searching or filtering a post list table.
Download this release

Release Info

Developer bradyvercher
Plugin Icon 128x128 Simple Page Sidebars
Version 1.1.6
Comparing to
See all releases

Code changes from version 1.1.5 to 1.1.6

Files changed (3) hide show
  1. admin/admin.php +6 -5
  2. readme.txt +4 -1
  3. simple-page-sidebars.php +1 -1
admin/admin.php CHANGED
@@ -219,7 +219,8 @@ class Simple_Page_Sidebars_Admin {
219
  }
220
 
221
  // Add the nonce here and copy it to the inline editor with javascript.
222
- wp_nonce_field( 'update-page-sidebar_' . $page_id, 'simplepagesidebars_page_sidebar_update_nonce', false );
 
223
  }
224
  }
225
 
@@ -251,6 +252,7 @@ class Simple_Page_Sidebars_Admin {
251
  ?>
252
  </select>
253
  </label>
 
254
  </div>
255
  </div>
256
  </fieldset>
@@ -283,7 +285,8 @@ class Simple_Page_Sidebars_Admin {
283
 
284
  var postId = inlineEditPost.getId( id ),
285
  currentSidebar = $( '#post-' + postId + ' .simple-page-sidebar' ).text(),
286
- sidebarNameField = $( '#simple-page-sidebars-page-sidebar-name' );
 
287
 
288
  // Select the current sidebar option.
289
  sidebarNameField.find( 'option' ).attr( 'selected', false );
@@ -292,9 +295,7 @@ class Simple_Page_Sidebars_Admin {
292
  }
293
 
294
  // Copy the sidebar name nonce.
295
- $( '#simple-page-sidebars-page-sidebar-edit-group' )
296
- .find( 'input[name="simplepagesidebars_page_sidebar_update_nonce"]' ).remove().end()
297
- .append( $( '#post-' + postId + ' input[name="simplepagesidebars_page_sidebar_update_nonce"]' ).clone() );
298
  };
299
  } )( window, jQuery );
300
  </script>
219
  }
220
 
221
  // Add the nonce here and copy it to the inline editor with javascript.
222
+ $nonce = wp_create_nonce( 'update-page-sidebar_' . $page_id );
223
+ printf( '<input type="hidden" value="%s" class="simplepagesidebars_page_sidebar_update_nonce">', esc_attr( $nonce ) );
224
  }
225
  }
226
 
252
  ?>
253
  </select>
254
  </label>
255
+ <?php wp_nonce_field( 'update-page-sidebar', 'simplepagesidebars_page_sidebar_update_nonce', false ); ?>
256
  </div>
257
  </div>
258
  </fieldset>
285
 
286
  var postId = inlineEditPost.getId( id ),
287
  currentSidebar = $( '#post-' + postId + ' .simple-page-sidebar' ).text(),
288
+ sidebarNameField = $( '#simple-page-sidebars-page-sidebar-name' ),
289
+ $nonceField = $( '#simple-page-sidebars-page-sidebar-edit-group' ).find( 'input[name="simplepagesidebars_page_sidebar_update_nonce"]' );
290
 
291
  // Select the current sidebar option.
292
  sidebarNameField.find( 'option' ).attr( 'selected', false );
295
  }
296
 
297
  // Copy the sidebar name nonce.
298
+ $nonceField.val( $( '#post-' + postId + ' .simplepagesidebars_page_sidebar_update_nonce' ).val() );
 
 
299
  };
300
  } )( window, jQuery );
301
  </script>
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: blazersix, bradyvercher
3
  Donate link: http://bit.ly/s2zcgD
4
  Tags: sidebars, custom sidebars, dynamic sidebar, simple, widget, widgets
5
  Requires at least: 3.4.2
6
- Tested up to: 3.7.1
7
  Stable tag: trunk
8
  License: GPL-2.0+
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
@@ -87,6 +87,9 @@ Some themes register different sidebars for their page templates, which means th
87
 
88
  == Changelog ==
89
 
 
 
 
90
  = 1.1.5 =
91
  * Added Serbo-Croatian translation.
92
 
3
  Donate link: http://bit.ly/s2zcgD
4
  Tags: sidebars, custom sidebars, dynamic sidebar, simple, widget, widgets
5
  Requires at least: 3.4.2
6
+ Tested up to: 4.0
7
  Stable tag: trunk
8
  License: GPL-2.0+
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
87
 
88
  == Changelog ==
89
 
90
+ = 1.1.6 =
91
+ * Prevent quick edit nonces from being submitted when searching or filtering a post list table.
92
+
93
  = 1.1.5 =
94
  * Added Serbo-Croatian translation.
95
 
simple-page-sidebars.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Simple Page Sidebars
4
  * Plugin URI: http://wordpress.org/extend/plugins/simple-page-sidebars/
5
  * Description: Assign custom, widget-enabled sidebars to any page with ease.
6
- * Version: 1.1.5
7
  * Author: Blazer Six
8
  * Author URI: http://www.blazersix.com/
9
  * License: GPL-2.0+
3
  * Plugin Name: Simple Page Sidebars
4
  * Plugin URI: http://wordpress.org/extend/plugins/simple-page-sidebars/
5
  * Description: Assign custom, widget-enabled sidebars to any page with ease.
6
+ * Version: 1.1.6
7
  * Author: Blazer Six
8
  * Author URI: http://www.blazersix.com/
9
  * License: GPL-2.0+