Widgets on Pages - Version 1.1.1

Version Description

  1. Bugfix - remove TurboSidebars from Search results
Download this release

Release Info

Developer toddhalfpenny
Plugin Icon 128x128 Widgets on Pages
Version 1.1.1
Comparing to
See all releases

Code changes from version 1.1.0 to 1.1.1

admin/class-widgets-on-pages-admin.php CHANGED
@@ -73,7 +73,7 @@ class Widgets_On_Pages_Admin
73
  3
74
  );
75
  }
76
-
77
  /**
78
  * Sets "Settings" link on listing in Plugins screen.
79
  *
@@ -86,7 +86,7 @@ class Widgets_On_Pages_Admin
86
  'settings' => '<a href="' . admin_url( '/options-general.php?page=widgets-on-pages' ) . '">' . __( 'Settings', 'widgets-on-pages' ) . '</a>',
87
  ), $links );
88
  }
89
-
90
  /**
91
  * Adds extra links under plugin description in listing on Plugins screen.
92
  *
@@ -96,7 +96,7 @@ class Widgets_On_Pages_Admin
96
  */
97
  public function wop_register_plugins_links( $links, $file )
98
  {
99
-
100
  if ( strpos( $file, $this->plugin_name ) !== false ) {
101
  $new_links = array(
102
  'donate' => '<a href="https://datamad.co.uk/donate.php" target="_blank">Donate</a>',
@@ -104,10 +104,10 @@ class Widgets_On_Pages_Admin
104
  );
105
  $links = array_merge( $links, $new_links );
106
  }
107
-
108
  return $links;
109
  }
110
-
111
  /**
112
  * Adds Admin Menu item.
113
  *
@@ -143,7 +143,7 @@ class Widgets_On_Pages_Admin
143
  'edit.php?post_type=turbo-sidebar-cpt'
144
  );
145
  }
146
-
147
  /**
148
  * Register our setting
149
  *
@@ -153,7 +153,7 @@ class Widgets_On_Pages_Admin
153
  {
154
  register_setting( 'wop_options', 'wop_options_field' );
155
  }
156
-
157
  /**
158
  * Render the options page for plugin
159
  *
@@ -163,7 +163,7 @@ class Widgets_On_Pages_Admin
163
  {
164
  include_once 'partials/widgets-on-pages-admin-display.php';
165
  }
166
-
167
  /**
168
  * Render the options page for plugin
169
  *
@@ -174,16 +174,16 @@ class Widgets_On_Pages_Admin
174
  */
175
  public function wop_plugin_help( $text, $screen_id, $screen )
176
  {
177
-
178
  if ( $screen_id == $this->wop_option_screen_id ) {
179
  $text = '<h5>Need help with the Widgets on Pages plugin?</h5>';
180
  $text .= '<p>Check out the documentation and support forums for help with this plugin.</p>';
181
  $text .= '<a href="http://wordpress.org/extend/plugins/widgets-on-pages/">Documentation</a><br /><a href="https://wordpress.org/support/plugin/widgets-on-pages/">Support forums</a>';
182
  }
183
-
184
  return $text;
185
  }
186
-
187
  /**
188
  * Removes meta boxes from admin screen
189
  *
@@ -193,7 +193,7 @@ class Widgets_On_Pages_Admin
193
  {
194
  remove_meta_box( 'postexcerpt', 'turbo-sidebar-cpt', 'normal' );
195
  }
196
-
197
  /**
198
  * Adds meta boxes from admin screen
199
  *
@@ -211,7 +211,7 @@ class Widgets_On_Pages_Admin
211
  null
212
  );
213
  }
214
-
215
  /**
216
  * Shortcode metabox markup
217
  *
@@ -224,7 +224,7 @@ class Widgets_On_Pages_Admin
224
  $shortcode_id = '[widgets_on_pages id="' . $object->post_title . '"]';
225
  echo '<p id="wop-shortcode">' . $shortcode_id . '</p>' ;
226
  }
227
-
228
  /**
229
  * Creates a new Turbo Sidebars custom post type
230
  *
@@ -240,7 +240,7 @@ class Widgets_On_Pages_Admin
240
  $opts['can_export'] = true;
241
  $opts['capability_type'] = $cap_type;
242
  $opts['description'] = '';
243
- $opts['exclude_from_search'] = false;
244
  $opts['has_archive'] = false;
245
  $opts['hierarchical'] = false;
246
  $opts['map_meta_cap'] = true;
@@ -293,7 +293,7 @@ class Widgets_On_Pages_Admin
293
  $opts = apply_filters( 'turbo-sidebars-cpt-options', $opts );
294
  register_post_type( strtolower( $cpt_name ), $opts );
295
  }
296
-
297
  /**
298
  * Register the sidebars, based upon our Turbo Sidebars.
299
  *
@@ -309,7 +309,7 @@ class Widgets_On_Pages_Admin
309
  $loop = new WP_Query( $args );
310
  while ( $loop->have_posts() ) {
311
  $loop->the_post();
312
-
313
  if ( is_numeric( $loop->post->post_name ) ) {
314
  $name = 'Widgets on Pages ' . $loop->post->post_name;
315
  $shortcode_id = $loop->post->post_name;
@@ -319,7 +319,7 @@ class Widgets_On_Pages_Admin
319
  $id = 'wop-' . $loop->post->post_name;
320
  $shortcode_id = $loop->post->post_title;
321
  }
322
-
323
  if ( '' != $loop->post->post_excerpt ) {
324
  $id = 'wop-' . $loop->post->post_excerpt;
325
  }
@@ -336,7 +336,7 @@ class Widgets_On_Pages_Admin
336
  ) );
337
  }
338
  }
339
-
340
  /**
341
  * Register the stylesheets for the admin area.
342
  *
@@ -363,7 +363,7 @@ class Widgets_On_Pages_Admin
363
  'all'
364
  );
365
  }
366
-
367
  /**
368
  * Register the JavaScript for the admin area.
369
  *
73
  3
74
  );
75
  }
76
+
77
  /**
78
  * Sets "Settings" link on listing in Plugins screen.
79
  *
86
  'settings' => '<a href="' . admin_url( '/options-general.php?page=widgets-on-pages' ) . '">' . __( 'Settings', 'widgets-on-pages' ) . '</a>',
87
  ), $links );
88
  }
89
+
90
  /**
91
  * Adds extra links under plugin description in listing on Plugins screen.
92
  *
96
  */
97
  public function wop_register_plugins_links( $links, $file )
98
  {
99
+
100
  if ( strpos( $file, $this->plugin_name ) !== false ) {
101
  $new_links = array(
102
  'donate' => '<a href="https://datamad.co.uk/donate.php" target="_blank">Donate</a>',
104
  );
105
  $links = array_merge( $links, $new_links );
106
  }
107
+
108
  return $links;
109
  }
110
+
111
  /**
112
  * Adds Admin Menu item.
113
  *
143
  'edit.php?post_type=turbo-sidebar-cpt'
144
  );
145
  }
146
+
147
  /**
148
  * Register our setting
149
  *
153
  {
154
  register_setting( 'wop_options', 'wop_options_field' );
155
  }
156
+
157
  /**
158
  * Render the options page for plugin
159
  *
163
  {
164
  include_once 'partials/widgets-on-pages-admin-display.php';
165
  }
166
+
167
  /**
168
  * Render the options page for plugin
169
  *
174
  */
175
  public function wop_plugin_help( $text, $screen_id, $screen )
176
  {
177
+
178
  if ( $screen_id == $this->wop_option_screen_id ) {
179
  $text = '<h5>Need help with the Widgets on Pages plugin?</h5>';
180
  $text .= '<p>Check out the documentation and support forums for help with this plugin.</p>';
181
  $text .= '<a href="http://wordpress.org/extend/plugins/widgets-on-pages/">Documentation</a><br /><a href="https://wordpress.org/support/plugin/widgets-on-pages/">Support forums</a>';
182
  }
183
+
184
  return $text;
185
  }
186
+
187
  /**
188
  * Removes meta boxes from admin screen
189
  *
193
  {
194
  remove_meta_box( 'postexcerpt', 'turbo-sidebar-cpt', 'normal' );
195
  }
196
+
197
  /**
198
  * Adds meta boxes from admin screen
199
  *
211
  null
212
  );
213
  }
214
+
215
  /**
216
  * Shortcode metabox markup
217
  *
224
  $shortcode_id = '[widgets_on_pages id="' . $object->post_title . '"]';
225
  echo '<p id="wop-shortcode">' . $shortcode_id . '</p>' ;
226
  }
227
+
228
  /**
229
  * Creates a new Turbo Sidebars custom post type
230
  *
240
  $opts['can_export'] = true;
241
  $opts['capability_type'] = $cap_type;
242
  $opts['description'] = '';
243
+ $opts['exclude_from_search'] = true;
244
  $opts['has_archive'] = false;
245
  $opts['hierarchical'] = false;
246
  $opts['map_meta_cap'] = true;
293
  $opts = apply_filters( 'turbo-sidebars-cpt-options', $opts );
294
  register_post_type( strtolower( $cpt_name ), $opts );
295
  }
296
+
297
  /**
298
  * Register the sidebars, based upon our Turbo Sidebars.
299
  *
309
  $loop = new WP_Query( $args );
310
  while ( $loop->have_posts() ) {
311
  $loop->the_post();
312
+
313
  if ( is_numeric( $loop->post->post_name ) ) {
314
  $name = 'Widgets on Pages ' . $loop->post->post_name;
315
  $shortcode_id = $loop->post->post_name;
319
  $id = 'wop-' . $loop->post->post_name;
320
  $shortcode_id = $loop->post->post_title;
321
  }
322
+
323
  if ( '' != $loop->post->post_excerpt ) {
324
  $id = 'wop-' . $loop->post->post_excerpt;
325
  }
336
  ) );
337
  }
338
  }
339
+
340
  /**
341
  * Register the stylesheets for the admin area.
342
  *
363
  'all'
364
  );
365
  }
366
+
367
  /**
368
  * Register the JavaScript for the admin area.
369
  *
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://datamad.co.uk/donate/
4
  Tags: widgets, widgets in page, widgets in post, sidebar, pages, post, shortcode, inline, widgetise, widgetize, theme
5
  Requires at least: 2.8
6
  Tested up to: 4.8
7
- Stable tag: 1.1.0
8
 
9
  The easiest and highest rated way to Add Widgets or Sidebars to Posts and Pages using shortcodes or template tags.
10
 
@@ -32,7 +32,7 @@ https://www.youtube.com/watch?v=w2LfCihCqRI
32
 
33
  **Current Features Include**
34
 
35
- * Highest Rating - 118 5* Reviews
36
  * No Coding needed
37
  * Create unlimited sidebars
38
  * Place them in posts/pages/custom post types
@@ -85,6 +85,11 @@ Yes... you can have an unlimited number of sidebars defined. The number availabl
85
 
86
  == Changelog ==
87
 
 
 
 
 
 
88
  = 1.1.0 =
89
 
90
  1. Analytics inclusion for support and ongoing maintenance
4
  Tags: widgets, widgets in page, widgets in post, sidebar, pages, post, shortcode, inline, widgetise, widgetize, theme
5
  Requires at least: 2.8
6
  Tested up to: 4.8
7
+ Stable tag: 1.1.1
8
 
9
  The easiest and highest rated way to Add Widgets or Sidebars to Posts and Pages using shortcodes or template tags.
10
 
32
 
33
  **Current Features Include**
34
 
35
+ * Highest Rating - 120 5* Reviews
36
  * No Coding needed
37
  * Create unlimited sidebars
38
  * Place them in posts/pages/custom post types
85
 
86
  == Changelog ==
87
 
88
+ = 1.1.1 =
89
+
90
+ 1. Bugfix - remove TurboSidebars from Search results
91
+
92
+
93
  = 1.1.0 =
94
 
95
  1. Analytics inclusion for support and ongoing maintenance
widgets_on_pages.php CHANGED
@@ -11,7 +11,7 @@
11
  * Plugin Name: Widgets On Pages
12
  * Plugin URI: https://datamad.co.uk/widgets-on-pages
13
  * Description: The easiest way to Add Widgets or Sidebars to Posts and Pages using shortcodes or template tags.
14
- * Version: 1.1.0
15
  * Author: Todd Halfpenny
16
  * Author URI: http://toddhalfpenny.com/
17
  * License: GPL-2.0+
@@ -26,7 +26,7 @@
26
  function wop_fs()
27
  {
28
  global $wop_fs ;
29
-
30
  if ( !isset( $wop_fs ) ) {
31
  // Include Freemius SDK.
32
  require_once dirname( __FILE__ ) . '/freemius/start.php';
@@ -45,7 +45,7 @@ function wop_fs()
45
  'is_live' => true,
46
  ) );
47
  }
48
-
49
  return $wop_fs;
50
  }
51
 
@@ -83,7 +83,7 @@ if ( !defined( 'WPINC' ) ) {
83
  die;
84
  }
85
  if ( !defined( 'WOP_PLUGIN_VERSION' ) ) {
86
- define( 'WOP_PLUGIN_VERSION', '1.1.0' );
87
  }
88
  /**
89
  * The code that runs during plugin activation.
11
  * Plugin Name: Widgets On Pages
12
  * Plugin URI: https://datamad.co.uk/widgets-on-pages
13
  * Description: The easiest way to Add Widgets or Sidebars to Posts and Pages using shortcodes or template tags.
14
+ * Version: 1.1.1
15
  * Author: Todd Halfpenny
16
  * Author URI: http://toddhalfpenny.com/
17
  * License: GPL-2.0+
26
  function wop_fs()
27
  {
28
  global $wop_fs ;
29
+
30
  if ( !isset( $wop_fs ) ) {
31
  // Include Freemius SDK.
32
  require_once dirname( __FILE__ ) . '/freemius/start.php';
45
  'is_live' => true,
46
  ) );
47
  }
48
+
49
  return $wop_fs;
50
  }
51
 
83
  die;
84
  }
85
  if ( !defined( 'WOP_PLUGIN_VERSION' ) ) {
86
+ define( 'WOP_PLUGIN_VERSION', '1.1.1' );
87
  }
88
  /**
89
  * The code that runs during plugin activation.