mirror of
https://github.com/10h30/genesis-simple-sidebars.git
synced 2026-07-11 18:46:05 +09:00
Tagging 0.9.2.
This commit is contained in:
+9
-1
@@ -50,6 +50,10 @@ function ss_create_sidebar( $args = array() ) {
|
||||
// nonce verification
|
||||
check_admin_referer('simple-sidebars-action_create-sidebar');
|
||||
|
||||
// WP changes a numeric sidebar id to sidebar-id which makes it inaccessible to the user
|
||||
if ( is_numeric( $args['id'] ) )
|
||||
$args['id'] = sanitize_title_with_dashes( $args['name'] );
|
||||
|
||||
$db = (array)get_option(SS_SETTINGS_FIELD);
|
||||
$new = array(
|
||||
sanitize_title_with_dashes( $args['id'] ) => array(
|
||||
@@ -81,6 +85,10 @@ function ss_edit_sidebar( $args = array() ) {
|
||||
// nonce verification
|
||||
check_admin_referer('simple-sidebars-action_edit-sidebar');
|
||||
|
||||
// WP changes a numeric sidebar id to sidebar-id which makes it inaccessible to the user
|
||||
if ( is_numeric( $args['id'] ) )
|
||||
$args['id'] = sanitize_title_with_dashes( $args['name'] );
|
||||
|
||||
$db = (array)get_option(SS_SETTINGS_FIELD);
|
||||
$new = array(
|
||||
sanitize_title_with_dashes( $args['id'] ) => array(
|
||||
@@ -137,7 +145,7 @@ function ss_error_message( $error = false ) {
|
||||
return __('Oops! Please choose a valid Name and ID for this sidebar', 'ss');
|
||||
break;
|
||||
case 2:
|
||||
return __('Oops! That sidebar ID already exists');
|
||||
return __('Oops! That sidebar ID already exists', 'ss');
|
||||
break;
|
||||
case 3:
|
||||
return __('Oops! You are trying to edit a sidebar that does not exist, or is not editable', 'ss');
|
||||
|
||||
Reference in New Issue
Block a user