Gallery – Photo Gallery and Images Gallery - Version 2.8.16

Version Description

  • Fix of the Gutenberg block for the old Gutenberg version compatibility
Download this release

Release Info

Developer robosoft
Plugin Icon 128x128 Gallery – Photo Gallery and Images Gallery
Version 2.8.16
Comparing to
See all releases

Code changes from version 2.8.15 to 2.8.16

app/app.php CHANGED
@@ -2,7 +2,7 @@
2
 
3
  /*
4
  * Robo Gallery
5
- * Version: 2.8.16 - 59839
6
  * By Robosoft
7
  *
8
  * Contact: https://robosoft.co/robogallery/
2
 
3
  /*
4
  * Robo Gallery
5
+ * Version: 2.8.17 - 40162
6
  * By Robosoft
7
  *
8
  * Contact: https://robosoft.co/robogallery/
app/class.brand.php CHANGED
@@ -2,7 +2,7 @@
2
 
3
  /*
4
  * Robo Gallery
5
- * Version: 2.8.16 - 59839
6
  * By Robosoft
7
  *
8
  * Contact: https://robosoft.co/robogallery/
2
 
3
  /*
4
  * Robo Gallery
5
+ * Version: 2.8.17 - 40162
6
  * By Robosoft
7
  *
8
  * Contact: https://robosoft.co/robogallery/
app/class.listing.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
  <?php
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/class.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
  <?php
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/class.view.php CHANGED
@@ -2,7 +2,7 @@
2
 
3
  /*
4
  * Robo Gallery
5
- * Version: 2.8.16 - 59839
6
  * By Robosoft
7
  *
8
  * Contact: https://robosoft.co/robogallery/
2
 
3
  /*
4
  * Robo Gallery
5
+ * Version: 2.8.17 - 40162
6
  * By Robosoft
7
  *
8
  * Contact: https://robosoft.co/robogallery/
app/extensions/dashboard/assets/style.css CHANGED
@@ -1,7 +1,7 @@
1
 
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
 
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/extensions/dashboard/class.dashboard.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
  <?php
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/extensions/dashboard/init.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
  <?php
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/extensions/dashboard/overview.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
  <?php
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/extensions/dashboard/video_guide.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
  <?php
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/extensions/manager/class.addons.action.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
  <?php
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/extensions/manager/class.addons.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
  <?php
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/extensions/manager/css/style.css CHANGED
@@ -1,6 +1,6 @@
1
  /*
2
  * Robo Gallery
3
- * Version: 2.8.16 - 59839
4
  * By Robosoft
5
  *
6
  * Contact: https://robosoft.co/robogallery/
1
  /*
2
  * Robo Gallery
3
+ * Version: 2.8.17 - 40162
4
  * By Robosoft
5
  *
6
  * Contact: https://robosoft.co/robogallery/
app/extensions/manager/init.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  * Robo Gallery
4
- * Version: 2.8.16 - 59839
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
1
  <?php
2
  /*
3
  * Robo Gallery
4
+ * Version: 2.8.17 - 40162
5
  * By Robosoft
6
  *
7
  * Contact: https://robosoft.co/robogallery/
app/extensions/manager/js/script.js CHANGED
@@ -1,6 +1,6 @@
1
  /*
2
  * Robo Gallery
3
- * Version: 2.8.16 - 59839
4
  * By Robosoft
5
  *
6
  * Contact: https://robosoft.co/robogallery/
1
  /*
2
  * Robo Gallery
3
+ * Version: 2.8.17 - 40162
4
  * By Robosoft
5
  *
6
  * Contact: https://robosoft.co/robogallery/
includes/extensions/block/src/init.php CHANGED
@@ -1,107 +1,128 @@
1
  <?php
2
 
3
- if ( ! defined( 'ABSPATH' ) ) {
4
- exit;
5
- }
6
 
7
- /*add_filter( 'block_categories', 'block_robo_gallery_add_category', 10, 2 );
8
 
9
- function block_robo_gallery_add_category( $categories, $post ) {
10
- return array_merge(
11
- $categories,
12
- array(
13
- array(
14
- 'slug' => 'robo-blocks',
15
- 'title' => __( 'Robo Gallery Blocks', 'robo-gallery' ),
16
- 'icon' => 'wordpress',
17
- ),
18
- )
19
- );
20
- }*/
21
-
22
- function block_robo_gallery_block_assets(){
23
- wp_enqueue_style(
24
- 'block_robo_gallery-style-css',
25
- plugins_url( 'dist/blocks.style.build.css', dirname( __FILE__ ) ),
26
- array( 'wp-editor' ),
27
- ROBO_GALLERY_VERSION
28
- );
29
- }
30
- add_action( 'enqueue_block_assets', 'block_robo_gallery_block_assets' );
31
 
32
- function block_robo_gallery_editor_assets(){
 
33
 
34
- wp_enqueue_script(
35
- 'block_robo_gallery-block-js',
36
- plugins_url( '/dist/blocks.build.js', dirname( __FILE__ ) ),
37
- array( 'wp-blocks', 'wp-i18n', 'wp-element', 'wp-editor' ),
38
- ROBO_GALLERY_VERSION,
39
- true // Enqueue the script in the footer.
40
- );
41
 
42
- wp_enqueue_style(
43
- 'block_robo_gallery-block-editor-css',
44
- plugins_url( 'dist/blocks.editor.build.css', dirname( __FILE__ ) ),
45
- array( 'wp-edit-blocks' ),
46
- ROBO_GALLERY_VERSION
47
- );
48
- }
49
 
50
- add_action( 'enqueue_block_editor_assets', 'block_robo_gallery_editor_assets' );
 
51
 
52
- register_block_type( 'robo/block-robo-gallery', array(
53
- 'render_callback' => 'roboGalleryRenderGutenbergBlock',
54
- 'attributes' => array(
55
- 'galleryid' => array(
56
- 'type' => 'number',
57
- 'default' => 99,
58
- ),
59
- ),
60
- ) );
61
 
62
- function roboGalleryRenderGutenbergBlock( $attributes, $content ) {
63
-
64
- if( is_array($attributes) && isset($attributes['galleryid']) && $attributes['galleryid']>0 ){
65
- if(class_exists('roboGallery')){
66
- $attr = array('id'=>$attributes['galleryid']);
67
- $gallery = new roboGallery($attr);
68
- return $gallery->getGallery();
69
- } else return 'Robo Gallery:: Error 999';
70
-
71
- } else {
72
- return sprintf(
73
- '<div><strong>%s</strong>: %s</div>',
74
- 'Robo Gallery',
75
- __("You didn't select any Robo Gallery item in editor. Please select one from the list or create new gallery",'robo-gallery')
76
- ) ;
77
- }
78
- }
79
 
80
- add_action( 'wp_ajax_robo_gallery_get_gallery_json','roboGalleryGetGalleryListJson' );
 
 
 
 
 
 
81
 
82
- function roboGalleryGetGalleryListJson() {
 
 
 
 
 
 
83
 
84
- $query = new WP_Query(
85
- array(
86
- 'post_type' => ROBO_GALLERY_TYPE_POST,
87
- 'post_status' => array( 'publish', 'private', 'future' )
88
- )
89
- );
90
 
91
- $posts = $query->posts;
 
 
92
 
93
- $returnJson = array();
 
 
 
 
 
 
 
 
94
 
95
- if( is_array($posts) && count($posts)){
96
- foreach($posts as $post) {
97
- $returnJson[] = array(
98
- 'id' => $post->ID,
99
- 'title' => esc_js($post->post_title),
100
- 'parent' => $post->post_parent,
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
101
  );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
102
  }
103
  }
104
-
105
- wp_send_json( $returnJson );
106
- wp_die();
107
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  <?php
2
 
3
+ if ( ! class_exists( 'RoboGallery_Blocks' ) ) {
 
 
4
 
5
+ class RoboGallery_Blocks {
6
 
7
+ public $prefix = 'block-robo-gallery-';
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8
 
9
+ function __construct() {
10
+ add_action( 'enqueue_block_assets', array( $this, 'block_assets') );
11
 
12
+ add_action( 'enqueue_block_editor_assets', array( $this, 'editor_assets') );
 
 
 
 
 
 
13
 
14
+ add_action( 'init', array( $this, 'php_block_init' ) );
 
 
 
 
 
 
15
 
16
+ add_action( 'wp_ajax_robo_gallery_get_gallery_json', array($this, 'ajaxGetGalleryJson') );
17
+ }
18
 
19
+ function block_assets(){
20
+ wp_enqueue_style(
21
+ $this->prefix.'style-css',
22
+ plugins_url( 'dist/blocks.style.build.css', dirname( __FILE__ ) ),
23
+ array( 'wp-editor' ),
24
+ ROBO_GALLERY_VERSION
25
+ );
26
+ }
 
27
 
28
+ function editor_assets(){
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
29
 
30
+ wp_enqueue_script(
31
+ $this->prefix.'block-js',
32
+ plugins_url( '/dist/blocks.build.js', dirname( __FILE__ ) ),
33
+ array( 'wp-blocks', 'wp-i18n', 'wp-element', 'wp-editor' ),
34
+ ROBO_GALLERY_VERSION,
35
+ true // Enqueue the script in the footer.
36
+ );
37
 
38
+ wp_enqueue_style(
39
+ $this->prefix.'block-editor-css',
40
+ plugins_url( 'dist/blocks.editor.build.css', dirname( __FILE__ ) ),
41
+ array( 'wp-edit-blocks' ),
42
+ ROBO_GALLERY_VERSION
43
+ );
44
+ }
45
 
46
+ function php_block_init(){
 
 
 
 
 
47
 
48
+ if ( !function_exists( 'register_block_type' ) ) {
49
+ return;
50
+ }
51
 
52
+ register_block_type( 'robo/block-robo-gallery', array(
53
+ 'render_callback' => array( $this, 'renderBlock'),
54
+ 'attributes' => array(
55
+ 'galleryid' => array(
56
+ 'type' => 'number',
57
+ 'default' => 99,
58
+ ),
59
+ ),
60
+ ) );
61
 
62
+ }
63
+
64
+ function renderBlock( $attributes ) {
65
+
66
+ if( is_array($attributes) && isset($attributes['galleryid']) && $attributes['galleryid']>0 ){
67
+ if(class_exists('roboGallery')){
68
+ $attr = array('id'=>$attributes['galleryid']);
69
+ $gallery = new roboGallery($attr);
70
+ return $gallery->getGallery();
71
+ } else return 'Robo Gallery:: Error 999';
72
+
73
+ } else {
74
+ return sprintf(
75
+ '<div><strong>%s</strong>: %s</div>',
76
+ 'Robo Gallery',
77
+ __("You didn't select any Robo Gallery item in editor. Please select one from the list or create new gallery",'robo-gallery')
78
+ ) ;
79
+ }
80
+ }
81
+
82
+ function ajaxGetGalleryJson() {
83
+
84
+ $query = new WP_Query(
85
+ array(
86
+ 'post_type' => ROBO_GALLERY_TYPE_POST,
87
+ 'post_status' => array( 'publish', 'private', 'future' )
88
+ )
89
  );
90
+
91
+ $posts = $query->posts;
92
+
93
+ $returnJson = array();
94
+
95
+ if( is_array($posts) && count($posts)){
96
+ foreach($posts as $post) {
97
+ $returnJson[] = array(
98
+ 'id' => $post->ID,
99
+ 'title' => esc_js($post->post_title),
100
+ 'parent' => $post->post_parent,
101
+ );
102
+ }
103
+ }
104
+
105
+ wp_send_json( $returnJson );
106
+ wp_die();
107
  }
108
  }
 
 
 
109
  }
110
+
111
+ new RoboGallery_Blocks();
112
+
113
+
114
+
115
+ /*add_filter( 'block_categories', 'block_robo_gallery_add_category', 10, 2 );
116
+
117
+ function block_robo_gallery_add_category( $categories, $post ) {
118
+ return array_merge(
119
+ $categories,
120
+ array(
121
+ array(
122
+ 'slug' => 'robo-blocks',
123
+ 'title' => __( 'Robo Gallery Blocks', 'robo-gallery' ),
124
+ 'icon' => 'wordpress',
125
+ ),
126
+ )
127
+ );
128
+ }*/
includes/rbs_gallery_init.php CHANGED
@@ -229,4 +229,5 @@ if(!function_exists('rbs_gallery_main_init')){
229
 
230
  add_action( 'plugins_loaded', 'rbs_gallery_main_init' );
231
 
 
232
  require_once ROBO_GALLERY_EXTENSIONS_PATH . 'block/src/init.php';
229
 
230
  add_action( 'plugins_loaded', 'rbs_gallery_main_init' );
231
 
232
+
233
  require_once ROBO_GALLERY_EXTENSIONS_PATH . 'block/src/init.php';
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://robosoft.co/robogallery
4
  Tags: gallery, photo gallery, image gallery, wordpress gallery plugin, responsive gallery
5
  Requires at least: 3.3
6
  Tested up to: 5.0
7
- Stable tag: 2.8.15
8
  License: GPLv2 or later
9
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
10
 
@@ -46,7 +46,8 @@ Gallery on your website it's really attractive and very important part of your p
46
 
47
 
48
  = Key Features =
49
-
 
50
  * **Fully responsive and Mobile features** - plugin implemented with advanced settings for different devices screen size.
51
  * **Fade effects** - one of the hover animation it's classic fade effect.
52
  * **Batch images upload** - advanced media manager which allow to upload batch of the images by one click. Just drag and drop set of the gallery images and it's upload automatically to the server.
@@ -202,6 +203,9 @@ If any problem occurs, please contact us.
202
 
203
  == Changelog ==
204
 
 
 
 
205
  = 2.8.15 =
206
  * Added Gutenberg editor support
207
  * Added Gutenberg block
@@ -479,6 +483,9 @@ If any problem occurs, please contact us.
479
 
480
  == Upgrade Notice ==
481
 
 
 
 
482
  = 2.8.15 =
483
  Added Gutenberg editor support
484
  Added Gutenberg block
4
  Tags: gallery, photo gallery, image gallery, wordpress gallery plugin, responsive gallery
5
  Requires at least: 3.3
6
  Tested up to: 5.0
7
+ Stable tag: 2.8.16
8
  License: GPLv2 or later
9
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
10
 
46
 
47
 
48
  = Key Features =
49
+
50
+ * **Gutenberg block** - implemented Gutenberg gallery block for simple and fast configuration of the plugin in Gutenberg editor.
51
  * **Fully responsive and Mobile features** - plugin implemented with advanced settings for different devices screen size.
52
  * **Fade effects** - one of the hover animation it's classic fade effect.
53
  * **Batch images upload** - advanced media manager which allow to upload batch of the images by one click. Just drag and drop set of the gallery images and it's upload automatically to the server.
203
 
204
  == Changelog ==
205
 
206
+ = 2.8.16 =
207
+ * Fix of the Gutenberg block for the old Gutenberg version compatibility
208
+
209
  = 2.8.15 =
210
  * Added Gutenberg editor support
211
  * Added Gutenberg block
483
 
484
  == Upgrade Notice ==
485
 
486
+ = 2.8.16 =
487
+ Fix of the Gutenberg block for the old Gutenberg version compatibility
488
+
489
  = 2.8.15 =
490
  Added Gutenberg editor support
491
  Added Gutenberg block
robogallery.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Robo Gallery
4
  Plugin URI: https://robosoft.co/wordpress-gallery-plugin
5
  Description: Gallery modes photo gallery, images gallery, video gallery, Polaroid gallery, gallery lighbox, portfolio gallery, responsive gallery
6
- Version: 2.8.15
7
  Author: RoboSoft
8
  Author URI: https://robosoft.co/wordpress-gallery-plugin
9
  License: GPLv3 or later
@@ -15,7 +15,7 @@ if(!defined('WPINC'))die;
15
  if(!defined("ABSPATH"))exit;
16
 
17
  define("ROBO_GALLERY", 1);
18
- define("ROBO_GALLERY_VERSION", '2.8.15');
19
 
20
  define("ROBO_GALLERY_OPTIONS", 'rbs_opt_');
21
 
3
  Plugin Name: Robo Gallery
4
  Plugin URI: https://robosoft.co/wordpress-gallery-plugin
5
  Description: Gallery modes photo gallery, images gallery, video gallery, Polaroid gallery, gallery lighbox, portfolio gallery, responsive gallery
6
+ Version: 2.8.16
7
  Author: RoboSoft
8
  Author URI: https://robosoft.co/wordpress-gallery-plugin
9
  License: GPLv3 or later
15
  if(!defined("ABSPATH"))exit;
16
 
17
  define("ROBO_GALLERY", 1);
18
+ define("ROBO_GALLERY_VERSION", '2.8.16');
19
 
20
  define("ROBO_GALLERY_OPTIONS", 'rbs_opt_');
21