Responsive Lightbox - Version 1.3.3

Version Description

Download this release

Release Info

Developer subhansanjaya
Plugin Icon 128x128 Responsive Lightbox
Version 1.3.3
Comparing to
See all releases

Code changes from version 1.3.2 to 1.3.3

assets/nivo-lightbox/nivo-lightbox.min.js CHANGED
File without changes
assets/nivo-lightbox/themes/default/default.css CHANGED
@@ -58,6 +58,7 @@
58
  }
59
 
60
  .nivo-lightbox-theme-default .nivo-lightbox-image img {
 
61
  background: #fff;
62
  -webkit-box-shadow: 0px 1px 1px rgba(0,0,0,0.4);
63
  -moz-box-shadow: 0px 1px 1px rgba(0,0,0,0.4);
58
  }
59
 
60
  .nivo-lightbox-theme-default .nivo-lightbox-image img {
61
+ margin: auto;
62
  background: #fff;
63
  -webkit-box-shadow: 0px 1px 1px rgba(0,0,0,0.4);
64
  -moz-box-shadow: 0px 1px 1px rgba(0,0,0,0.4);
readme.txt CHANGED
@@ -5,9 +5,9 @@ Author URI: http://weaveapps.com
5
  Plugin URI: http://wordpress.org/plugins/responsive-lightbox-lite/
6
  Donate link:https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=BXBCGCKDD74UE
7
  Tags: responsive Lightbox, Lightbox, Nivo Lightbox, pop up, modal window, modal dialog, pop-up, light box, lightbox for youtube, nivo, wp lightbox,iframe pop up,pop up, wordpress lightbox
8
- Requires at least: 3.5
9
- Tested up to: 4.9
10
- Stable tag: 1.3.2
11
  License: GPLv2 or later
12
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
13
 
@@ -24,6 +24,30 @@ Responsive Lightbox Wordpress plugin adds Lightbox functionality for images, htm
24
  * Option to set automatically add Lightbox to your images, gallery, videos etc.
25
  * Customisable through settings and CSS.
26
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
27
  == Installation ==
28
 
29
  **Installation Instruction & Configuration**
5
  Plugin URI: http://wordpress.org/plugins/responsive-lightbox-lite/
6
  Donate link:https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=BXBCGCKDD74UE
7
  Tags: responsive Lightbox, Lightbox, Nivo Lightbox, pop up, modal window, modal dialog, pop-up, light box, lightbox for youtube, nivo, wp lightbox,iframe pop up,pop up, wordpress lightbox
8
+ Requires at least: 4.5
9
+ Tested up to: 5.3
10
+ Stable tag: 1.3.3
11
  License: GPLv2 or later
12
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
13
 
24
  * Option to set automatically add Lightbox to your images, gallery, videos etc.
25
  * Customisable through settings and CSS.
26
 
27
+ = Responsive LightBox - Pro =
28
+ Please, click [here](http://weaveapps.com/shop/wordpress-plugins/responsive-lightbox-wordpress-plugin/). to check the pro version.
29
+
30
+ = Features of the pro version of the plugin =
31
+ * Fully responsive and HiDPI compatible.
32
+ * Designed to work with the both classic and gutenberg editors
33
+ * Touch enabled and mobile friendly.
34
+ * Option to add LightBox functionality automatically to your images, gallery, videos etc.
35
+ * 7 built in CSS powered effects (Fade, Slide, Fall etc.).
36
+ * Show image captions automatically.
37
+ * Add LightBox functionality for any type of content such as images, image galleries, AJAX, iFrame, Flash, Youtube or Vimeo videos, another website, inline content, HTML etc.
38
+ * Easy to use standard admin interface with more than 15 options.
39
+ * 2 built in themes and simple templating system add your own theme easily.
40
+ * Translation ready.
41
+ * Multisite support.
42
+ * Search engine optimised.
43
+ * Light weight. (Smaller file size which load faster.).
44
+ * Support all browsers: Firefox, Chrome, IE, Safari etc.
45
+ * Compatible with any theme.
46
+ * Developed in best practices of CSS3 and HTML5.
47
+ * Easy to customise through settings and custom option to override styles, if necessary without editing the css files.
48
+ * Change default colors with color pickers.
49
+ * Integrated with automatic updates.
50
+
51
  == Installation ==
52
 
53
  **Installation Instruction & Configuration**
responsive-lightbox-lite.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Responsive Lightbox
4
  * Description: This plugin offers a nice and elegant way to add Lightbox functionality for images, html content and media on your webpages.
5
  * Author: subhansanjaya
6
- * Version: 1.3.2
7
  * Plugin URI: http://wordpress.org/plugins/responsive-lightbox-lite/
8
  * Author URI: http://weaveapps.com
9
  * Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=BXBCGCKDD74UE
@@ -29,7 +29,7 @@ class Responsive_Lightbox_Lite {
29
  'enable_custom_events' => false,
30
  'custom_events' => 'ajaxComplete'
31
  ),
32
- 'version' => '1.0.0'
33
  );
34
  private $options = array();
35
  private $tabs = array();
@@ -66,6 +66,9 @@ class Responsive_Lightbox_Lite {
66
 
67
  if($this->options['settings']['image_links'] === TRUE || $this->options['settings']['images_as_gallery'] === TRUE)
68
  add_filter('the_content', array(&$this, 'add_lightbox_selector_images_links'));
 
 
 
69
  }
70
 
71
  //activation hook
@@ -95,6 +98,38 @@ class Responsive_Lightbox_Lite {
95
  return (preg_match('/<a.*? href=("|\').*?("|\')>/', $link) === 1 ? preg_replace('/(<a.*? href=(?:"|\')).*?((?:"|\').*?>)/', '$1'.wp_get_attachment_url($id).'$2', $link) : preg_replace('/(<a.*?)>/', '$1 href="'.wp_get_attachment_url($id).'">', $link));
96
  }
97
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
98
  /* add lightbox selectors for videos */
99
  public function add_lightbox_selector_videos($content)
100
  {
@@ -377,7 +412,7 @@ class Responsive_Lightbox_Lite {
377
  {
378
  $tab_key = (isset($_GET['tab']) ? $_GET['tab'] : 'general-settings');
379
 
380
- echo '<div class="wrap">'.screen_icon().'
381
  <h2>'.__('Responsive Lightbox Lite', 'responsive-lightbox-lite').'</h2>
382
  <h2 class="nav-tab-wrapper">';
383
 
3
  * Plugin Name: Responsive Lightbox
4
  * Description: This plugin offers a nice and elegant way to add Lightbox functionality for images, html content and media on your webpages.
5
  * Author: subhansanjaya
6
+ * Version: 1.3.3
7
  * Plugin URI: http://wordpress.org/plugins/responsive-lightbox-lite/
8
  * Author URI: http://weaveapps.com
9
  * Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=BXBCGCKDD74UE
29
  'enable_custom_events' => false,
30
  'custom_events' => 'ajaxComplete'
31
  ),
32
+ 'version' => '1.3.3'
33
  );
34
  private $options = array();
35
  private $tabs = array();
66
 
67
  if($this->options['settings']['image_links'] === TRUE || $this->options['settings']['images_as_gallery'] === TRUE)
68
  add_filter('the_content', array(&$this, 'add_lightbox_selector_images_links'));
69
+
70
+ if($this->options['settings']['galleries'] === TRUE)
71
+ add_filter('the_content', array(&$this, 'add_lightbox_selector_gallery_gb'));
72
  }
73
 
74
  //activation hook
98
  return (preg_match('/<a.*? href=("|\').*?("|\')>/', $link) === 1 ? preg_replace('/(<a.*? href=(?:"|\')).*?((?:"|\').*?>)/', '$1'.wp_get_attachment_url($id).'$2', $link) : preg_replace('/(<a.*?)>/', '$1 href="'.wp_get_attachment_url($id).'">', $link));
99
  }
100
 
101
+ // Add lightbox selector for gutenberg editor based galleries
102
+ public function add_lightbox_selector_gallery_gb($content) {
103
+
104
+ preg_match_all('/<ul class=\"blocks-gallery-grid\">(.*?)<\/ul>/s',$content,$linkss);
105
+
106
+ $var = 1;
107
+
108
+ foreach($linkss[0] as $id => $linkx) {
109
+
110
+ $var++;
111
+
112
+ preg_match_all( '/<figure>(.*?)<\/figure>/s' , $linkx, $links );
113
+
114
+ foreach($links[0] as $link) {
115
+
116
+ preg_match_all('/<figcaption class=\"blocks-gallery-item__caption\">(.*?)<\/figcaption>/s',$link,$urls);
117
+
118
+ $src = array_pop($urls);
119
+
120
+ $find = array('/rel=(?:\'|")(.*?)(?:\'|")/');
121
+ $replace = array('rel="lightbox[gallery-'.$var.']"');
122
+
123
+ $content = str_replace($link, preg_replace($find, $replace, $link), $content);
124
+
125
+ }
126
+
127
+ }
128
+
129
+ return $content;
130
+
131
+ }
132
+
133
  /* add lightbox selectors for videos */
134
  public function add_lightbox_selector_videos($content)
135
  {
412
  {
413
  $tab_key = (isset($_GET['tab']) ? $_GET['tab'] : 'general-settings');
414
 
415
+ echo '<div class="wrap">
416
  <h2>'.__('Responsive Lightbox Lite', 'responsive-lightbox-lite').'</h2>
417
  <h2 class="nav-tab-wrapper">';
418