Content Aware Sidebars – Unlimited Widget Areas - Version 3.14.1

Version Description

  • [fixed] sidebar quick select now displays all eligible sidebars
  • [updated] reinstate widgets screen if disabled by gutenberg plugin without user consent

Pro Plan:

  • [fixed] styles would not always be loaded for container widget
Download this release

Release Info

Developer intoxstudio
Plugin Icon 128x128 Content Aware Sidebars – Unlimited Widget Areas
Version 3.14.1
Comparing to
See all releases

Code changes from version 3.14 to 3.14.1

Files changed (4) hide show
  1. admin/quick_select.php +16 -12
  2. app.php +6 -1
  3. content-aware-sidebars.php +1 -1
  4. readme.txt +11 -2
admin/quick_select.php CHANGED
@@ -205,9 +205,11 @@ class CAS_Quick_Select
205
  $host_meta = CAS_App::instance()->manager()->metadata()->get('host');
206
  foreach ($relations as $sidebar_id => $group_id) {
207
  if (isset($sidebars[CAS_App::SIDEBAR_PREFIX.$sidebar_id])) {
208
- $host_id = $host_meta->get_data($sidebar_id);
209
- if (!isset(self::$_theme_sidebars[$host_id])) {
210
- continue;
 
 
211
  }
212
  }
213
 
@@ -240,14 +242,16 @@ class CAS_Quick_Select
240
  $manager = CAS_App::instance()->manager();
241
  $host_meta = $manager->metadata()->get('host');
242
  foreach ($manager->sidebars as $sidebar) {
243
- $host_id = $host_meta->get_data($sidebar->ID);
244
- if (isset(self::$_theme_sidebars[$host_id])) {
245
- self::$_theme_sidebars[$host_id]['options'][$sidebar->ID] = array(
246
- 'id' => $sidebar->ID,
247
- 'text' => $sidebar->post_title.self::sidebar_states($sidebar)
248
- );
249
- if (isset($post_sidebars[$sidebar->ID])) {
250
- self::$_theme_sidebars[$host_id]['options'][$sidebar->ID]['select'] = 1;
 
 
251
  }
252
  }
253
  }
@@ -396,7 +400,7 @@ class CAS_Quick_Select
396
  INNER JOIN $wpdb->postmeta gm ON gm.post_id = g.ID AND gm.meta_key = '".WPCACore::PREFIX.self::MODULE_NAME."'
397
  WHERE s.post_status <> 'trash'
398
  AND s.post_type = '".CAS_App::TYPE_SIDEBAR."'
399
- AND g.post_status = '".WPCACore::STATUS_PUBLISHED."'
400
  AND gm.meta_value = %d
401
  ORDER BY s.post_title ASC",
402
  $post->ID
205
  $host_meta = CAS_App::instance()->manager()->metadata()->get('host');
206
  foreach ($relations as $sidebar_id => $group_id) {
207
  if (isset($sidebars[CAS_App::SIDEBAR_PREFIX.$sidebar_id])) {
208
+ $host_ids = $host_meta->get_data($sidebar_id, false, false);
209
+ foreach ($host_ids as $host_id) {
210
+ if (!isset(self::$_theme_sidebars[$host_id])) {
211
+ continue;
212
+ }
213
  }
214
  }
215
 
242
  $manager = CAS_App::instance()->manager();
243
  $host_meta = $manager->metadata()->get('host');
244
  foreach ($manager->sidebars as $sidebar) {
245
+ $host_ids = $host_meta->get_data($sidebar->ID, false, false);
246
+ foreach ($host_ids as $host_id) {
247
+ if (isset(self::$_theme_sidebars[$host_id])) {
248
+ self::$_theme_sidebars[$host_id]['options'][$sidebar->ID] = array(
249
+ 'id' => $sidebar->ID,
250
+ 'text' => $sidebar->post_title.self::sidebar_states($sidebar)
251
+ );
252
+ if (isset($post_sidebars[$sidebar->ID])) {
253
+ self::$_theme_sidebars[$host_id]['options'][$sidebar->ID]['select'] = 1;
254
+ }
255
  }
256
  }
257
  }
400
  INNER JOIN $wpdb->postmeta gm ON gm.post_id = g.ID AND gm.meta_key = '".WPCACore::PREFIX.self::MODULE_NAME."'
401
  WHERE s.post_status <> 'trash'
402
  AND s.post_type = '".CAS_App::TYPE_SIDEBAR."'
403
+ AND g.post_status IN ('".WPCACore::STATUS_PUBLISHED."','".WPCACore::STATUS_OR."')
404
  AND gm.meta_value = %d
405
  ORDER BY s.post_title ASC",
406
  $post->ID
app.php CHANGED
@@ -11,7 +11,7 @@ defined('ABSPATH') || exit;
11
  final class CAS_App
12
  {
13
  const PLUGIN_VERSION_KEY = 'cas_db_version';
14
- const PLUGIN_VERSION = '3.14';
15
 
16
  /**
17
  * Prefix for sidebar id
@@ -148,6 +148,11 @@ final class CAS_App
148
  99,
149
  4
150
  );
 
 
 
 
 
151
  }
152
  }
153
 
11
  final class CAS_App
12
  {
13
  const PLUGIN_VERSION_KEY = 'cas_db_version';
14
+ const PLUGIN_VERSION = '3.14.1';
15
 
16
  /**
17
  * Prefix for sidebar id
148
  99,
149
  4
150
  );
151
+ /**
152
+ * gutenberg disables widgets screen without user consent,
153
+ * reenable by popular demand for now
154
+ */
155
+ add_filter('gutenberg_use_widgets_block_editor','__return_false');
156
  }
157
  }
158
 
content-aware-sidebars.php CHANGED
@@ -9,7 +9,7 @@
9
  Plugin Name: Content Aware Sidebars
10
  Plugin URI: https://dev.institute/wordpress-sidebars/
11
  Description: Unlimited custom sidebars and widget areas for any post, page, category etc.
12
- Version: 3.14
13
  Author: Joachim Jensen - DEV Institute
14
  Author URI: https://dev.institute
15
  Requires at least: 4.9
9
  Plugin Name: Content Aware Sidebars
10
  Plugin URI: https://dev.institute/wordpress-sidebars/
11
  Description: Unlimited custom sidebars and widget areas for any post, page, category etc.
12
+ Version: 3.14.1
13
  Author: Joachim Jensen - DEV Institute
14
  Author URI: https://dev.institute
15
  Requires at least: 4.9
readme.txt CHANGED
@@ -5,7 +5,7 @@ Tags: custom sidebars, sidebar, hide sidebar, display widgets, widget, bbpress,
5
  Requires at least: 4.9
6
  Requires PHP: 5.6
7
  Tested up to: 5.6
8
- Stable tag: 3.14
9
  License: GPLv3
10
 
11
  Display new sidebars and widget areas on any post, page, category etc. Works with all themes, no code required.
@@ -49,7 +49,7 @@ In the All-in-one Sidebar Manager you **just pick a start and end date** for whe
49
 
50
  > **1-Click Sidebar Activation&copy; lets you activate or deactivate widget areas instantly.**
51
 
52
- ####The Most User-friendly Widget Manager
53
 
54
  When adding new widgets to sidebars, **Live Search will find widgets instantly**, and the smart split-screen makes it a joy to manage a lot of widgets and sidebars.
55
 
@@ -184,6 +184,15 @@ Of course! Check out the links below:
184
 
185
  ####Highlights
186
 
 
 
 
 
 
 
 
 
 
187
  = 3.14 =
188
 
189
  * [new] ability to replace or merge with multiple sidebars
5
  Requires at least: 4.9
6
  Requires PHP: 5.6
7
  Tested up to: 5.6
8
+ Stable tag: 3.14.1
9
  License: GPLv3
10
 
11
  Display new sidebars and widget areas on any post, page, category etc. Works with all themes, no code required.
49
 
50
  > **1-Click Sidebar Activation&copy; lets you activate or deactivate widget areas instantly.**
51
 
52
+ ###The Most User-friendly Widget Manager
53
 
54
  When adding new widgets to sidebars, **Live Search will find widgets instantly**, and the smart split-screen makes it a joy to manage a lot of widgets and sidebars.
55
 
184
 
185
  ####Highlights
186
 
187
+ = 3.14.1 =
188
+
189
+ * [fixed] sidebar quick select now displays all eligible sidebars
190
+ * [updated] reinstate widgets screen if disabled by gutenberg plugin without user consent
191
+
192
+ **Pro Plan:**
193
+
194
+ * [fixed] styles would not always be loaded for container widget
195
+
196
  = 3.14 =
197
 
198
  * [new] ability to replace or merge with multiple sidebars