All-in-One Video Gallery - Version 2.4.8

Version Description

  • Fix: WordPress 5.8 compatibility issues.
Download this release

Release Info

Developer plugins360
Plugin Icon 128x128 All-in-One Video Gallery
Version 2.4.8
Comparing to
See all releases

Code changes from version 2.4.7 to 2.4.8

README.txt CHANGED
@@ -4,9 +4,9 @@ Contributors: plugins360, wpvideogallery, freemius
4
  Donate link: https://plugins360.com
5
  Tags: video player, video gallery, youtube gallery, vimeo gallery, livestream
6
  Requires at least: 4.7.0
7
- Tested up to: 5.7
8
  Requires PHP: 5.6.20
9
- Stable tag: 2.4.7
10
  License: GPLv2 or later
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
@@ -134,6 +134,10 @@ Yes, it is. However, do not "network-activate" the plugin. Activate it only on t
134
 
135
  == Changelog ==
136
 
 
 
 
 
137
  = 2.4.7 =
138
 
139
  * Fix: Error when you click the "Add More Quality Levels" in the video form but submitting the form without selecting any quality level.
@@ -224,3 +228,7 @@ Yes, it is. However, do not "network-activate" the plugin. Activate it only on t
224
  For the changelog of earlier versions, please refer to the [changelog on plugins360.com](https://plugins360.com/all-in-one-video-gallery/changelog/).
225
 
226
  == Upgrade Notice ==
 
 
 
 
4
  Donate link: https://plugins360.com
5
  Tags: video player, video gallery, youtube gallery, vimeo gallery, livestream
6
  Requires at least: 4.7.0
7
+ Tested up to: 5.8
8
  Requires PHP: 5.6.20
9
+ Stable tag: 2.4.8
10
  License: GPLv2 or later
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
134
 
135
  == Changelog ==
136
 
137
+ = 2.4.8 =
138
+
139
+ * Fix: WordPress 5.8 compatibility issues.
140
+
141
  = 2.4.7 =
142
 
143
  * Fix: Error when you click the "Add More Quality Levels" in the video form but submitting the form without selecting any quality level.
228
  For the changelog of earlier versions, please refer to the [changelog on plugins360.com](https://plugins360.com/all-in-one-video-gallery/changelog/).
229
 
230
  == Upgrade Notice ==
231
+
232
+ = 2.4.8 =
233
+
234
+ Fix: WordPress 5.8 compatibility issues. [See changelog](https://wordpress.org/plugins/all-in-one-video-gallery/#developers)
admin/assets/css/admin.css CHANGED
@@ -582,6 +582,23 @@ table.aiovg-table .aiovg-handle {
582
  margin: 15px 0;
583
  }
584
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
585
  .aiovg-widget-form .aiovg-widget-label {
586
  display: block;
587
  margin-bottom: 5px;
582
  margin: 15px 0;
583
  }
584
 
585
+ .branch-5-8 .aiovg-widget-form .aiovg-widget-field {
586
+ margin: 7px 0;
587
+ }
588
+
589
+ .branch-5-8 .aiovg-widget-form .aiovg-checklist {
590
+ padding: 7px;
591
+ box-sizing: border-box;
592
+ }
593
+
594
+ .branch-5-8 .aiovg-widget-form .aiovg-checklist li::marker {
595
+ content: "";
596
+ }
597
+
598
+ .branch-5-8 .aiovg-widget-form .aiovg-checklist label {
599
+ margin: 0;
600
+ }
601
+
602
  .aiovg-widget-form .aiovg-widget-label {
603
  display: block;
604
  margin-bottom: 5px;
all-in-one-video-gallery.php CHANGED
@@ -11,7 +11,7 @@
11
  * Plugin Name: All-in-One Video Gallery
12
  * Plugin URI: https://plugins360.com/all-in-one-video-gallery/
13
  * Description: No coding required. A Responsive & Lightweight video gallery plugin. HTML5 Player, Categories, Visual Builder (Gutenberg), Search Form, Comments, Social Sharing and everything you will need to build a YouTube/Vimeo like video sharing website.
14
- * Version: 2.4.7
15
  * Author: Team Plugins360
16
  * Author URI: https://plugins360.com
17
  * License: GPL-2.0+
@@ -76,7 +76,7 @@ if ( !function_exists( 'aiovg_fs' ) ) {
76
 
77
  // The current version of the plugin
78
  if ( !defined( 'AIOVG_PLUGIN_VERSION' ) ) {
79
- define( 'AIOVG_PLUGIN_VERSION', '2.4.7' );
80
  }
81
  // The unique identifier of the plugin
82
  if ( !defined( 'AIOVG_PLUGIN_SLUG' ) ) {
11
  * Plugin Name: All-in-One Video Gallery
12
  * Plugin URI: https://plugins360.com/all-in-one-video-gallery/
13
  * Description: No coding required. A Responsive & Lightweight video gallery plugin. HTML5 Player, Categories, Visual Builder (Gutenberg), Search Form, Comments, Social Sharing and everything you will need to build a YouTube/Vimeo like video sharing website.
14
+ * Version: 2.4.8
15
  * Author: Team Plugins360
16
  * Author URI: https://plugins360.com
17
  * License: GPL-2.0+
76
 
77
  // The current version of the plugin
78
  if ( !defined( 'AIOVG_PLUGIN_VERSION' ) ) {
79
+ define( 'AIOVG_PLUGIN_VERSION', '2.4.8' );
80
  }
81
  // The unique identifier of the plugin
82
  if ( !defined( 'AIOVG_PLUGIN_SLUG' ) ) {
includes/init.php CHANGED
@@ -284,12 +284,23 @@ class AIOVG_Init {
284
  * @access private
285
  */
286
  private function blocks_init() {
 
 
 
 
 
 
 
287
  $blocks = new AIOVG_Blocks();
288
 
289
  $this->loader->add_action( 'init', $blocks, 'register_block_types' );
290
  $this->loader->add_action( 'enqueue_block_editor_assets', $blocks, 'enqueue_block_editor_assets' );
291
 
292
- $this->loader->add_filter( 'block_categories', $blocks, 'block_categories' );
 
 
 
 
293
  }
294
 
295
  /**
284
  * @access private
285
  */
286
  private function blocks_init() {
287
+ if ( is_admin() ) {
288
+ global $pagenow;
289
+ if ( 'widgets.php' === $pagenow ) return;
290
+ }
291
+
292
+ global $wp_version;
293
+
294
  $blocks = new AIOVG_Blocks();
295
 
296
  $this->loader->add_action( 'init', $blocks, 'register_block_types' );
297
  $this->loader->add_action( 'enqueue_block_editor_assets', $blocks, 'enqueue_block_editor_assets' );
298
 
299
+ if ( version_compare( $wp_version, '5.8', '>=' ) ) {
300
+ $this->loader->add_filter( 'block_categories_all', $blocks, 'block_categories' );
301
+ } else {
302
+ $this->loader->add_filter( 'block_categories', $blocks, 'block_categories' );
303
+ }
304
  }
305
 
306
  /**
widgets/categories.php CHANGED
@@ -176,11 +176,11 @@ class AIOVG_Widget_Categories extends WP_Widget {
176
  $instance['limit'] = isset( $new_instance['limit'] ) ? (int) $new_instance['limit'] : 0;
177
  $instance['orderby'] = isset( $new_instance['orderby'] ) ? sanitize_text_field( $new_instance['orderby'] ) : 'name';
178
  $instance['order'] = isset( $new_instance['order'] ) ? sanitize_text_field( $new_instance['order'] ) : 'asc';
179
- $instance['hierarchical'] = isset( $new_instance['hierarchical'] ) ? 1 : 0;
180
- $instance['show_description'] = isset( $new_instance['show_description'] ) ? 1 : 0;
181
- $instance['show_count'] = isset( $new_instance['show_count'] ) ? 1 : 0;
182
- $instance['hide_empty'] = isset( $new_instance['hide_empty'] ) ? 1 : 0;
183
- $instance['show_more'] = isset( $new_instance['show_more'] ) ? 1 : 0;
184
  $instance['more_label'] = isset( $new_instance['more_label'] ) ? sanitize_text_field( $new_instance['more_label'] ) : '';
185
  $instance['more_link'] = isset( $new_instance['more_link'] ) ? esc_url_raw( $new_instance['more_link'] ) : '';
186
 
176
  $instance['limit'] = isset( $new_instance['limit'] ) ? (int) $new_instance['limit'] : 0;
177
  $instance['orderby'] = isset( $new_instance['orderby'] ) ? sanitize_text_field( $new_instance['orderby'] ) : 'name';
178
  $instance['order'] = isset( $new_instance['order'] ) ? sanitize_text_field( $new_instance['order'] ) : 'asc';
179
+ $instance['hierarchical'] = isset( $new_instance['hierarchical'] ) ? (int) $new_instance['hierarchical'] : 0;
180
+ $instance['show_description'] = isset( $new_instance['show_description'] ) ? (int) $new_instance['show_description'] : 0;
181
+ $instance['show_count'] = isset( $new_instance['show_count'] ) ? (int) $new_instance['show_count'] : 0;
182
+ $instance['hide_empty'] = isset( $new_instance['hide_empty'] ) ? (int) $new_instance['hide_empty'] : 0;
183
+ $instance['show_more'] = isset( $new_instance['show_more'] ) ? (int) $new_instance['show_more'] : 0;
184
  $instance['more_label'] = isset( $new_instance['more_label'] ) ? sanitize_text_field( $new_instance['more_label'] ) : '';
185
  $instance['more_link'] = isset( $new_instance['more_link'] ) ? esc_url_raw( $new_instance['more_link'] ) : '';
186
 
widgets/search.php CHANGED
@@ -53,12 +53,11 @@ class AIOVG_Widget_Search extends WP_Widget {
53
  * @param array $args
54
  * @param array $instance
55
  */
56
- public function widget( $args, $instance ) {
57
  // Vars
58
  $page_settings = get_option( 'aiovg_page_settings' );
59
 
60
  $attributes = array(
61
- 'widget_id' => $args['widget_id'] . '-wrapper',
62
  'template' => isset( $instance['template'] ) ? sanitize_text_field( $instance['template'] ) : 'vertical',
63
  'search_page_id' => $page_settings['search'],
64
  'has_keyword' => isset( $instance['has_keyword'] ) ? (int) $instance['has_keyword'] : 1,
@@ -103,9 +102,9 @@ class AIOVG_Widget_Search extends WP_Widget {
103
 
104
  $instance['title'] = isset( $new_instance['title'] ) ? strip_tags( $new_instance['title'] ) : '';
105
  $instance['template'] = isset( $new_instance['template'] ) ? sanitize_text_field( $new_instance['template'] ) : 'vertical';
106
- $instance['has_keyword'] = isset( $new_instance['has_keyword'] ) ? 1 : 0;
107
- $instance['has_category'] = isset( $new_instance['has_category'] ) ? 1 : 0;
108
- $instance['has_tag'] = isset( $new_instance['has_tag'] ) ? 1 : 0;
109
 
110
  return $instance;
111
  }
@@ -122,7 +121,7 @@ class AIOVG_Widget_Search extends WP_Widget {
122
  // Define the array of defaults
123
  $defaults = array(
124
  'title' => __( 'Search Videos', 'all-in-one-video-gallery' ),
125
- 'template' => 'horizontal',
126
  'has_keyword' => 1,
127
  'has_category' => 0,
128
  'has_tag' => 0
53
  * @param array $args
54
  * @param array $instance
55
  */
56
+ public function widget( $args, $instance ) {
57
  // Vars
58
  $page_settings = get_option( 'aiovg_page_settings' );
59
 
60
  $attributes = array(
 
61
  'template' => isset( $instance['template'] ) ? sanitize_text_field( $instance['template'] ) : 'vertical',
62
  'search_page_id' => $page_settings['search'],
63
  'has_keyword' => isset( $instance['has_keyword'] ) ? (int) $instance['has_keyword'] : 1,
102
 
103
  $instance['title'] = isset( $new_instance['title'] ) ? strip_tags( $new_instance['title'] ) : '';
104
  $instance['template'] = isset( $new_instance['template'] ) ? sanitize_text_field( $new_instance['template'] ) : 'vertical';
105
+ $instance['has_keyword'] = isset( $new_instance['has_keyword'] ) ? (int) $new_instance['has_keyword'] : 0;
106
+ $instance['has_category'] = isset( $new_instance['has_category'] ) ? (int) $new_instance['has_category'] : 0;
107
+ $instance['has_tag'] = isset( $new_instance['has_tag'] ) ? (int) $new_instance['has_tag'] : 0;
108
 
109
  return $instance;
110
  }
121
  // Define the array of defaults
122
  $defaults = array(
123
  'title' => __( 'Search Videos', 'all-in-one-video-gallery' ),
124
+ 'template' => 'vertical',
125
  'has_keyword' => 1,
126
  'has_category' => 0,
127
  'has_tag' => 0
widgets/video.php CHANGED
@@ -106,18 +106,18 @@ class AIOVG_Widget_Video extends WP_Widget {
106
  $instance['id'] = isset( $new_instance['id'] ) ? (int) $new_instance['id'] : '';
107
  $instance['width'] = isset( $new_instance['width'] ) ? sanitize_text_field( $new_instance['width'] ) : '';
108
  $instance['ratio'] = isset( $new_instance['ratio'] ) ? (float) $new_instance['ratio'] : 0;
109
- $instance['autoplay'] = isset( $new_instance['autoplay'] ) ? 1 : 0;
110
- $instance['loop'] = isset( $new_instance['loop'] ) ? 1 : 0;
111
- $instance['muted'] = isset( $new_instance['muted'] ) ? 1 : 0;
112
- $instance['playpause'] = isset( $new_instance['playpause'] ) ? 1 : 0;
113
- $instance['current'] = isset( $new_instance['current'] ) ? 1 : 0;
114
- $instance['progress'] = isset( $new_instance['progress'] ) ? 1 : 0;
115
- $instance['duration'] = isset( $new_instance['duration'] ) ? 1 : 0;
116
- $instance['tracks'] = isset( $new_instance['tracks'] ) ? 1 : 0;
117
- $instance['quality'] = isset( $new_instance['quality'] ) ? 1 : 0;
118
- $instance['speed'] = isset( $new_instance['speed'] ) ? 1 : 0;
119
- $instance['volume'] = isset( $new_instance['volume'] ) ? 1 : 0;
120
- $instance['fullscreen'] = isset( $new_instance['fullscreen'] ) ? 1 : 0;
121
 
122
  return $instance;
123
  }
106
  $instance['id'] = isset( $new_instance['id'] ) ? (int) $new_instance['id'] : '';
107
  $instance['width'] = isset( $new_instance['width'] ) ? sanitize_text_field( $new_instance['width'] ) : '';
108
  $instance['ratio'] = isset( $new_instance['ratio'] ) ? (float) $new_instance['ratio'] : 0;
109
+ $instance['autoplay'] = isset( $new_instance['autoplay'] ) ? (int) $new_instance['autoplay'] : 0;
110
+ $instance['loop'] = isset( $new_instance['loop'] ) ? (int) $new_instance['loop'] : 0;
111
+ $instance['muted'] = isset( $new_instance['muted'] ) ? (int) $new_instance['muted'] : 0;
112
+ $instance['playpause'] = isset( $new_instance['playpause'] ) ? (int) $new_instance['playpause'] : 0;
113
+ $instance['current'] = isset( $new_instance['current'] ) ? (int) $new_instance['current'] : 0;
114
+ $instance['progress'] = isset( $new_instance['progress'] ) ? (int) $new_instance['progress'] : 0;
115
+ $instance['duration'] = isset( $new_instance['duration'] ) ? (int) $new_instance['duration'] : 0;
116
+ $instance['tracks'] = isset( $new_instance['tracks'] ) ? (int) $new_instance['tracks'] : 0;
117
+ $instance['quality'] = isset( $new_instance['quality'] ) ? (int) $new_instance['quality'] : 0;
118
+ $instance['speed'] = isset( $new_instance['speed'] ) ? (int) $new_instance['speed'] : 0;
119
+ $instance['volume'] = isset( $new_instance['volume'] ) ? (int) $new_instance['volume'] : 0;
120
+ $instance['fullscreen'] = isset( $new_instance['fullscreen'] ) ? (int) $new_instance['fullscreen'] : 0;
121
 
122
  return $instance;
123
  }
widgets/videos.php CHANGED
@@ -243,7 +243,7 @@ class AIOVG_Widget_Videos extends WP_Widget {
243
  } elseif ( 'url' == $field['type'] ) {
244
  $instance[ $field_name ] = ! empty( $new_instance[ $field_name ] ) ? esc_url_raw( $new_instance[ $field_name ] ) : '';
245
  } elseif ( 'checkbox' == $field['type'] ) {
246
- $instance[ $field_name ] = isset( $new_instance[ $field_name ] ) ? 1 : 0;
247
  } else {
248
  $instance[ $field_name ] = ! empty( $new_instance[ $field_name ] ) ? sanitize_text_field( $new_instance[ $field_name ] ) : '';
249
  }
243
  } elseif ( 'url' == $field['type'] ) {
244
  $instance[ $field_name ] = ! empty( $new_instance[ $field_name ] ) ? esc_url_raw( $new_instance[ $field_name ] ) : '';
245
  } elseif ( 'checkbox' == $field['type'] ) {
246
+ $instance[ $field_name ] = isset( $new_instance[ $field_name ] ) ? (int) $new_instance[ $field_name ] : 0;
247
  } else {
248
  $instance[ $field_name ] = ! empty( $new_instance[ $field_name ] ) ? sanitize_text_field( $new_instance[ $field_name ] ) : '';
249
  }