Version Description
- Added better browser support for defer javascript loading added in 1.2.23
Download this release
Release Info
Developer | bradvin |
Plugin | FooBox Image Lightbox WordPress Plugin |
Version | 1.2.24 |
Comparing to | |
See all releases |
Code changes from version 1.2.22 to 1.2.24
- foobox-free.php +2 -2
- free/foobox-free.php +26 -1
- free/includes/class-settings.php +8 -0
- readme.txt +20 -15
foobox-free.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
Plugin Name: FooBox Image Lightbox
|
5 |
Plugin URI: http://fooplugins.com/plugins/foobox/
|
6 |
Description: The best responsive lightbox for WordPress.
|
7 |
-
Version: 1.2.
|
8 |
Author: FooPlugins
|
9 |
Author URI: http://fooplugins.com
|
10 |
License: GPL2
|
@@ -20,7 +20,7 @@ if ( !class_exists( 'FooBox' ) ) {
|
|
20 |
define( 'FOOBOX_BASE_ACTIVATION_REDIRECT_TRANSIENT_KEY', '_foobox_activation_redirect' );
|
21 |
define( 'FOOBOX_BASE_PATH', plugin_dir_path( __FILE__ ) );
|
22 |
define( 'FOOBOX_BASE_URL', plugin_dir_url( __FILE__ ) );
|
23 |
-
define( 'FOOBOX_BASE_VERSION', '1.2.
|
24 |
// Create a helper function for easy SDK access.
|
25 |
function foobox_fs()
|
26 |
{
|
4 |
Plugin Name: FooBox Image Lightbox
|
5 |
Plugin URI: http://fooplugins.com/plugins/foobox/
|
6 |
Description: The best responsive lightbox for WordPress.
|
7 |
+
Version: 1.2.24
|
8 |
Author: FooPlugins
|
9 |
Author URI: http://fooplugins.com
|
10 |
License: GPL2
|
20 |
define( 'FOOBOX_BASE_ACTIVATION_REDIRECT_TRANSIENT_KEY', '_foobox_activation_redirect' );
|
21 |
define( 'FOOBOX_BASE_PATH', plugin_dir_path( __FILE__ ) );
|
22 |
define( 'FOOBOX_BASE_URL', plugin_dir_url( __FILE__ ) );
|
23 |
+
define( 'FOOBOX_BASE_VERSION', '1.2.24' );
|
24 |
// Create a helper function for easy SDK access.
|
25 |
function foobox_fs()
|
26 |
{
|
free/foobox-free.php
CHANGED
@@ -152,7 +152,32 @@ if (!class_exists('Foobox_Free')) {
|
|
152 |
|
153 |
function inline_dynamic_js() {
|
154 |
$foobox_js = $this->generate_javascript();
|
155 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
156 |
}
|
157 |
|
158 |
/**
|
152 |
|
153 |
function inline_dynamic_js() {
|
154 |
$foobox_js = $this->generate_javascript();
|
155 |
+
|
156 |
+
$defer_js = !$this->is_option_checked( 'disable_defer_js', true );
|
157 |
+
|
158 |
+
$script_type = $defer_js ? 'text/foobox' : 'text/javascript';
|
159 |
+
|
160 |
+
echo '<script type="' . $script_type . '">' . $foobox_js . '</script>';
|
161 |
+
|
162 |
+
if ( $defer_js ) {
|
163 |
+
?>
|
164 |
+
<script type="text/javascript">
|
165 |
+
if (window.addEventListener){
|
166 |
+
window.addEventListener("DOMContentLoaded", function() {
|
167 |
+
var arr = document.querySelectorAll("script[type='text/foobox']");
|
168 |
+
for (var x = 0; x < arr.length; x++) {
|
169 |
+
var script = document.createElement("script");
|
170 |
+
script.type = "text/javascript";
|
171 |
+
script.innerHTML = arr[x].innerHTML;
|
172 |
+
arr[x].parentNode.replaceChild(script, arr[x]);
|
173 |
+
}
|
174 |
+
});
|
175 |
+
} else {
|
176 |
+
console.log("FooBox does not support the current browser.");
|
177 |
+
}
|
178 |
+
</script>
|
179 |
+
<?php
|
180 |
+
}
|
181 |
}
|
182 |
|
183 |
/**
|
free/includes/class-settings.php
CHANGED
@@ -146,6 +146,14 @@ if ( !class_exists( 'FooBox_Free_Settings' ) ) {
|
|
146 |
'tab' => 'advanced'
|
147 |
);
|
148 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
149 |
$settings[] = array(
|
150 |
'id' => 'dropie7support',
|
151 |
'title' => __( 'Drop IE7 Support', 'foobox' ),
|
146 |
'tab' => 'advanced'
|
147 |
);
|
148 |
|
149 |
+
$settings[] = array(
|
150 |
+
'id' => 'disable_defer_js',
|
151 |
+
'title' => __( 'Disable Defer Javascript', 'foobox' ),
|
152 |
+
'desc' => __( 'By default, we defer running the FooBox javascript to work with most optimization plugins. You can choose to turn this off if there are problems.', 'foobox-image-lightbox' ),
|
153 |
+
'type' => 'checkbox',
|
154 |
+
'tab' => 'advanced'
|
155 |
+
);
|
156 |
+
|
157 |
$settings[] = array(
|
158 |
'id' => 'dropie7support',
|
159 |
'title' => __( 'Drop IE7 Support', 'foobox' ),
|
readme.txt
CHANGED
@@ -1,4 +1,4 @@
|
|
1 |
-
=== FooBox Image Lightbox ===
|
2 |
Contributors: bradvin, fooplugins, freemius
|
3 |
Donate link: http://fooplugins.com
|
4 |
Tags: lightbox,media,images,gallery,modal
|
@@ -8,25 +8,25 @@ Stable tag: trunk
|
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
11 |
-
A responsive image lightbox for WordPress galleries &
|
12 |
|
13 |
== Description ==
|
14 |
|
15 |
FooBox was the first lightbox to take responsive layout seriously. Not only does it scale images to look better on phones, but it rearranges it's button controls to look great in both portrait or landscape orientation.
|
16 |
|
17 |
-
Works with most image gallery plugins, but works best with our
|
18 |
|
19 |
**Now includes a 7-day free trial of FooBox Pro!**
|
20 |
|
21 |
-
**Features
|
22 |
|
23 |
* Responsive design
|
24 |
* Sexy lightbox design
|
|
|
25 |
* Works with WordPress galleries
|
26 |
* Works with WordPress captioned images
|
27 |
-
* Zero configuration
|
28 |
|
29 |
-
**
|
30 |
|
31 |
* Social sharing (10+ networks)
|
32 |
* Video support
|
@@ -38,23 +38,18 @@ Works with most image gallery plugins, but works best with our free [FooGallery]
|
|
38 |
* 5 color schemes, 12 buttons icons and 11 loader icons
|
39 |
* 85+ settings to customize
|
40 |
|
41 |
-
**
|
42 |
|
43 |
-
* [
|
44 |
* NextGen
|
45 |
* [Justified Image Grid](http://codecanyon.net/item/justified-image-grid-premium-wordpress-gallery/2594251)
|
|
|
46 |
* WooCommerce product images
|
47 |
* JetPack Tiled Gallery
|
|
|
48 |
|
49 |
Check out the [full feature comparison](http://fooplugins.com/foobox-feature-comparison/?utm_source=fooboxfreeplugin&utm_medium=fooboxcomparelink&utm_campaign=foobox_free_wprepo).
|
50 |
|
51 |
-
**Partners**
|
52 |
-
|
53 |
-
FooBox works great with most themes and gallery plugins right out of the box. But some vendors go that extra mile to ensure 100% FooBox compatibility:
|
54 |
-
|
55 |
-
* [FooGallery](http://foo.gallery)
|
56 |
-
* [Bottomless Design WordPress Themes](http://www.mojo-themes.com/user/bottomlessdesign)
|
57 |
-
|
58 |
**Translations**
|
59 |
|
60 |
* [Serbo-Croatian by Borisa Djuraskovic](http://www.webhostinghub.com/)
|
@@ -66,6 +61,10 @@ FooBox works great with most themes and gallery plugins right out of the box. Bu
|
|
66 |
|
67 |
== Frequently Asked Questions ==
|
68 |
|
|
|
|
|
|
|
|
|
69 |
= My theme has a built-in lightbox and it shows under FooBox. What can I do? =
|
70 |
|
71 |
There is a setting to try and disable hard coded lightboxes, but this is not a sure-fire solution for every scenario. If that setting does not work for you, you might need to deregister certain javascript files, or uncomment certain lines of code in your theme to remove it's lightbox.
|
@@ -77,6 +76,12 @@ There is a setting to try and disable hard coded lightboxes, but this is not a s
|
|
77 |
|
78 |
== Changelog ==
|
79 |
|
|
|
|
|
|
|
|
|
|
|
|
|
80 |
= 1.2.22 =
|
81 |
* Updated to latest JS and CSS fixing multiple issues and bugs
|
82 |
|
1 |
+
=== FooBox Image Lightbox WordPress Plugin ===
|
2 |
Contributors: bradvin, fooplugins, freemius
|
3 |
Donate link: http://fooplugins.com
|
4 |
Tags: lightbox,media,images,gallery,modal
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
11 |
+
A responsive image lightbox for WordPress galleries, WordPress attachments & FooGallery
|
12 |
|
13 |
== Description ==
|
14 |
|
15 |
FooBox was the first lightbox to take responsive layout seriously. Not only does it scale images to look better on phones, but it rearranges it's button controls to look great in both portrait or landscape orientation.
|
16 |
|
17 |
+
Works with most image gallery plugins, but works best with our [FooGallery Image Gallery WordPress Plugin](http://foo.gallery).
|
18 |
|
19 |
**Now includes a 7-day free trial of FooBox Pro!**
|
20 |
|
21 |
+
**FooBox Image Lightbox Features:**
|
22 |
|
23 |
* Responsive design
|
24 |
* Sexy lightbox design
|
25 |
+
* Zero configuration!
|
26 |
* Works with WordPress galleries
|
27 |
* Works with WordPress captioned images
|
|
|
28 |
|
29 |
+
**[FooBox PRO](http://fooplugins.com/plugins/foobox/?utm_source=fooboxfreeplugin&utm_medium=fooboxfreeprolink&utm_campaign=foobox_free_wprepo) Features:**
|
30 |
|
31 |
* Social sharing (10+ networks)
|
32 |
* Video support
|
38 |
* 5 color schemes, 12 buttons icons and 11 loader icons
|
39 |
* 85+ settings to customize
|
40 |
|
41 |
+
**[FooBox PRO](http://fooplugins.com/plugins/foobox/?utm_source=fooboxfreeplugin&utm_medium=fooboxfreeprolink&utm_campaign=foobox_free_wprepo) Works With:**
|
42 |
|
43 |
+
* [The Best Image Gallery Plugin for WordPress](http://foo.gallery)
|
44 |
* NextGen
|
45 |
* [Justified Image Grid](http://codecanyon.net/item/justified-image-grid-premium-wordpress-gallery/2594251)
|
46 |
+
* Envira Gallery
|
47 |
* WooCommerce product images
|
48 |
* JetPack Tiled Gallery
|
49 |
+
* AutOptimize
|
50 |
|
51 |
Check out the [full feature comparison](http://fooplugins.com/foobox-feature-comparison/?utm_source=fooboxfreeplugin&utm_medium=fooboxcomparelink&utm_campaign=foobox_free_wprepo).
|
52 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
53 |
**Translations**
|
54 |
|
55 |
* [Serbo-Croatian by Borisa Djuraskovic](http://www.webhostinghub.com/)
|
61 |
|
62 |
== Frequently Asked Questions ==
|
63 |
|
64 |
+
= FooBox is not working. There is an error in the console "Uncaught ReferenceError: FooBox is not defined" =
|
65 |
+
|
66 |
+
Some plugins or themes defer javascript in the page, which causes the FooBox initialization code to run BEFORE the FooBox main script is loaded. This has been fixed in version 1.2.24. Please upgrade.
|
67 |
+
|
68 |
= My theme has a built-in lightbox and it shows under FooBox. What can I do? =
|
69 |
|
70 |
There is a setting to try and disable hard coded lightboxes, but this is not a sure-fire solution for every scenario. If that setting does not work for you, you might need to deregister certain javascript files, or uncomment certain lines of code in your theme to remove it's lightbox.
|
76 |
|
77 |
== Changelog ==
|
78 |
|
79 |
+
= 1.2.24 =
|
80 |
+
* Added better browser support for defer javascript loading added in 1.2.23
|
81 |
+
|
82 |
+
= 1.2.23 =
|
83 |
+
* Added support for plugins that defer javascript loading, e.g. AutOptimize
|
84 |
+
|
85 |
= 1.2.22 =
|
86 |
* Updated to latest JS and CSS fixing multiple issues and bugs
|
87 |
|