Easy FancyBox - Version 1.8.17

Version Description

Fix compat messages and links

=

Download this release

Release Info

Developer deployer
Plugin Icon 128x128 Easy FancyBox
Version 1.8.17
Comparing to
See all releases

Code changes from version 1.8.16 to 1.8.17

Files changed (53) hide show
  1. easy-fancybox.php +3 -3
  2. images/blank.gif +0 -0
  3. images/fancy_close.png +0 -0
  4. images/fancy_loading.png +0 -0
  5. images/fancy_nav_left.png +0 -0
  6. images/fancy_nav_right.png +0 -0
  7. images/fancy_shadow_e.png +0 -0
  8. images/fancy_shadow_n.png +0 -0
  9. images/fancy_shadow_ne.png +0 -0
  10. images/fancy_shadow_nw.png +0 -0
  11. images/fancy_shadow_s.png +0 -0
  12. images/fancy_shadow_se.png +0 -0
  13. images/fancy_shadow_sw.png +0 -0
  14. images/fancy_shadow_w.png +0 -0
  15. images/fancy_title_left.png +0 -0
  16. images/fancy_title_main.png +0 -0
  17. images/fancy_title_over.png +0 -0
  18. images/fancy_title_right.png +0 -0
  19. images/fancybox-x.png +0 -0
  20. images/fancybox-y.png +0 -0
  21. images/fancybox.png +0 -0
  22. images/light-mask.png +0 -0
  23. inc/class-easyfancybox-admin.php +35 -13
  24. inc/class-easyfancybox.php +24 -17
  25. inc/easyfancybox-options.php +1 -1
  26. languages/easy-fancybox-cs_CZ.mo +0 -0
  27. languages/easy-fancybox-cs_CZ.po +0 -0
  28. languages/easy-fancybox-es_ES.mo +0 -0
  29. languages/easy-fancybox-es_ES.po +0 -0
  30. languages/easy-fancybox-fa_IR.mo +0 -0
  31. languages/easy-fancybox-fa_IR.po +0 -0
  32. languages/easy-fancybox-fr_FR.mo +0 -0
  33. languages/easy-fancybox-fr_FR.po +0 -0
  34. languages/easy-fancybox-hi_IN.mo +0 -0
  35. languages/easy-fancybox-hi_IN.po +0 -0
  36. languages/easy-fancybox-hr.mo +0 -0
  37. languages/easy-fancybox-hr.po +0 -0
  38. languages/easy-fancybox-id_ID.mo +0 -0
  39. languages/easy-fancybox-id_ID.po +0 -0
  40. languages/easy-fancybox-lt_LT.mo +0 -0
  41. languages/easy-fancybox-lt_LT.po +0 -0
  42. languages/easy-fancybox-pl_PL.mo +0 -0
  43. languages/easy-fancybox-pl_PL.po +0 -0
  44. languages/easy-fancybox-readme-bel.po +6 -6
  45. languages/easy-fancybox-ro_RO.po +0 -0
  46. languages/easy-fancybox-sr_RS.mo +0 -0
  47. languages/easy-fancybox-sr_RS.po +0 -0
  48. languages/easy-fancybox-tr_TR.mo +0 -0
  49. languages/easy-fancybox-tr_TR.po +0 -0
  50. languages/easy-fancybox-ua_UA.mo +0 -0
  51. languages/easy-fancybox-ua_UA.po +0 -0
  52. languages/instructions.txt +0 -0
  53. readme.txt +14 -9
easy-fancybox.php CHANGED
@@ -5,12 +5,12 @@ Plugin URI: http://status301.net/wordpress-plugins/easy-fancybox/
5
  Description: Easily enable the <a href="http://fancybox.net/">FancyBox jQuery extension</a> on all image, SWF, PDF, YouTube, Dailymotion and Vimeo links. Also supports iFrame and inline content.
6
  Text Domain: easy-fancybox
7
  Domain Path: languages
8
- Version: 1.8.16
9
  Author: RavanH
10
  Author URI: http://status301.net/
11
  */
12
 
13
- /* Copyright 2018 RavanH (email : ravanhagen@gmail.com)
14
 
15
  This program is free software; you can redistribute it and/or modify
16
  it under the terms of the GNU General Public License as published by
@@ -37,7 +37,7 @@ if ( ! defined( 'ABSPATH' ) ) exit;
37
  * CONSTANTS
38
  **************/
39
 
40
- define( 'EASY_FANCYBOX_VERSION', '1.8.16' );
41
  define( 'FANCYBOX_VERSION', '1.3.24' );
42
  define( 'MOUSEWHEEL_VERSION', '3.1.13' );
43
  define( 'EASING_VERSION', '1.4.1' );
5
  Description: Easily enable the <a href="http://fancybox.net/">FancyBox jQuery extension</a> on all image, SWF, PDF, YouTube, Dailymotion and Vimeo links. Also supports iFrame and inline content.
6
  Text Domain: easy-fancybox
7
  Domain Path: languages
8
+ Version: 1.8.17
9
  Author: RavanH
10
  Author URI: http://status301.net/
11
  */
12
 
13
+ /* Copyright 2019 RavanH (email : ravanhagen@gmail.com)
14
 
15
  This program is free software; you can redistribute it and/or modify
16
  it under the terms of the GNU General Public License as published by
37
  * CONSTANTS
38
  **************/
39
 
40
+ define( 'EASY_FANCYBOX_VERSION', '1.8.17' );
41
  define( 'FANCYBOX_VERSION', '1.3.24' );
42
  define( 'MOUSEWHEEL_VERSION', '3.1.13' );
43
  define( 'EASING_VERSION', '1.4.1' );
images/blank.gif CHANGED
File without changes
images/fancy_close.png CHANGED
File without changes
images/fancy_loading.png CHANGED
File without changes
images/fancy_nav_left.png CHANGED
File without changes
images/fancy_nav_right.png CHANGED
File without changes
images/fancy_shadow_e.png CHANGED
File without changes
images/fancy_shadow_n.png CHANGED
File without changes
images/fancy_shadow_ne.png CHANGED
File without changes
images/fancy_shadow_nw.png CHANGED
File without changes
images/fancy_shadow_s.png CHANGED
File without changes
images/fancy_shadow_se.png CHANGED
File without changes
images/fancy_shadow_sw.png CHANGED
File without changes
images/fancy_shadow_w.png CHANGED
File without changes
images/fancy_title_left.png CHANGED
File without changes
images/fancy_title_main.png CHANGED
File without changes
images/fancy_title_over.png CHANGED
File without changes
images/fancy_title_right.png CHANGED
File without changes
images/fancybox-x.png CHANGED
File without changes
images/fancybox-y.png CHANGED
File without changes
images/fancybox.png CHANGED
File without changes
images/light-mask.png CHANGED
File without changes
inc/class-easyfancybox-admin.php CHANGED
@@ -11,14 +11,16 @@ class easyFancyBox_Admin extends easyFancyBox {
11
  public static $do_compat_warning = false;
12
 
13
  /***********************
14
- ADMIN FUNCTIONS
15
  ***********************/
16
 
17
- public static function add_settings_section() {
 
18
  add_settings_section('fancybox_section', __('FancyBox','easy-fancybox'), array(__CLASS__, 'settings_section'), 'media');
19
  }
20
 
21
- public static function register_settings( $args = array() ) {
 
22
  if ( empty( $args ) ) $args = parent::$options;
23
  foreach ($args as $key => $value) {
24
  // check to see if the section is enabled, else skip to next
@@ -57,7 +59,8 @@ class easyFancyBox_Admin extends easyFancyBox {
57
  }
58
 
59
  // add our FancyBox Media Settings Section on Settings > Media admin page
60
- public static function settings_section() {
 
61
  echo '<style type="text/css">.options-media-php br { display: initial; }</style><!-- undo WP style rule introduced in 4.9 on settings-media -->
62
  <p><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=ravanhagen%40gmail%2ecom&item_name=Easy%20FancyBox&item_number='.EASY_FANCYBOX_VERSION.'&no_shipping=0&tax=0&charset=UTF%2d8&currency_code=EUR" title="'.__('Donate to keep the Easy FancyBox plugin development going!','easy-fancybox').'">
63
  <img src="https://www.paypalobjects.com/en_US/i/btn/btn_donate_LG.gif" style="border:none;float:right;margin:5px 0 0 10px" alt="'.__('Donate to keep the Easy FancyBox plugin development going!','easy-fancybox').'" width="92" height="26" /></a>';
@@ -74,7 +77,7 @@ class easyFancyBox_Admin extends easyFancyBox {
74
  Black Friday to Cyber Monday: THE BIG 30 SALE at Status301.
75
  <em>A whopping 30% discount but only for the first 30 customers.
76
  After that, there will still be a discount of 15% for everybody until tuesday 0:00 GMT so
77
- <strong><a href="https://premium.status301.net/black-friday-til-cyber-monday-big-30-sale/?discount=BFCM30" target="_blank">to take advantage of this opportunity</a></strong>
78
  before it\'s too late</em>...</p>';
79
  }
80
 
@@ -84,7 +87,7 @@ class easyFancyBox_Admin extends easyFancyBox {
84
  _e('Notice: The current Easy FancyBox plugin version is not fully compatible with your version of the Pro extension. Some advanced options may not be functional.','easy-fancybox');
85
  echo ' ';
86
  if ( current_user_can( 'install_plugins' ) )
87
- printf(__('Please <a href="%1$s" target="_blank">download and install the latest Pro version</a>.','easy-fancybox'), 'https://premium.status301.net/account/');
88
  else
89
  _e('Please contact your web site administrator.','easy-fancybox');
90
  echo '</p>';
@@ -92,7 +95,8 @@ class easyFancyBox_Admin extends easyFancyBox {
92
  }
93
 
94
  // add our FancyBox Media Settings Fields
95
- public static function settings_fields($args){
 
96
  $disabled = (isset($args['status']) && 'disabled' == $args['status']) ? ' disabled="disabled"' : '';
97
  if (isset($args['input']))
98
  switch($args['input']) {
@@ -181,17 +185,32 @@ class easyFancyBox_Admin extends easyFancyBox {
181
  /**
182
  * Adds an action link to the Plugins page
183
  */
184
- public static function add_action_link( $links ) {
 
185
  $settings_link = '<a href="' . admin_url('options-media.php') . '">' . translate('Settings') . '</a>';
186
  array_unshift( $links, $settings_link );
187
  return $links;
188
  }
189
 
 
 
 
 
 
 
 
 
 
 
 
 
 
190
  /***
191
  * Santize Callbacks
192
  */
193
 
194
- public static function intval($setting = '') {
 
195
  if ($setting == '')
196
  return '';
197
 
@@ -234,18 +253,20 @@ class easyFancyBox_Admin extends easyFancyBox {
234
  //echo '<a href="?easy_fancybox_ignore_notice=1" title="' . __('Hide message','easy-fancybox') . '" style="display:block;float:right">X</a>';
235
  _e('Notice: The current Easy FancyBox plugin version is not fully compatible with your version of the Pro extension. Some advanced options may not be functional.','easy-fancybox');
236
  echo '<br />';
237
- printf(__('Please <a href="%1$s" target="_blank">download and install the latest Pro version</a>.','easy-fancybox'), 'https://premium.status301.net/account/');
238
  echo ' ';
239
  printf(__('Or you can ignore and <a href="%1$s">hide this message</a>.','easy-fancybox'), '?easy_fancybox_ignore_notice=1');
240
  echo '</p></div>';
241
  }
242
  }
243
 
244
- public static function load_textdomain() {
 
245
  load_plugin_textdomain('easy-fancybox', false, dirname( parent::$plugin_basename ) . '/languages' );
246
  }
247
 
248
- public static function admin_init() {
 
249
  /* Dismissable notice */
250
  /* If user clicks to ignore the notice, add that to their user meta */
251
  global $current_user;
@@ -263,7 +284,8 @@ class easyFancyBox_Admin extends easyFancyBox {
263
  RUN
264
  **********************/
265
 
266
- public function __construct() {
 
267
  add_action('plugins_loaded', array(__CLASS__, 'load_textdomain'));
268
  add_action('admin_notices', array(__CLASS__, 'admin_notice'));
269
  add_filter('plugin_action_links_'.parent::$plugin_basename, array(__CLASS__, 'add_action_link') );
11
  public static $do_compat_warning = false;
12
 
13
  /***********************
14
+ ADMIN METHODS
15
  ***********************/
16
 
17
+ public static function add_settings_section()
18
+ {
19
  add_settings_section('fancybox_section', __('FancyBox','easy-fancybox'), array(__CLASS__, 'settings_section'), 'media');
20
  }
21
 
22
+ public static function register_settings( $args = array() )
23
+ {
24
  if ( empty( $args ) ) $args = parent::$options;
25
  foreach ($args as $key => $value) {
26
  // check to see if the section is enabled, else skip to next
59
  }
60
 
61
  // add our FancyBox Media Settings Section on Settings > Media admin page
62
+ public static function settings_section()
63
+ {
64
  echo '<style type="text/css">.options-media-php br { display: initial; }</style><!-- undo WP style rule introduced in 4.9 on settings-media -->
65
  <p><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=ravanhagen%40gmail%2ecom&item_name=Easy%20FancyBox&item_number='.EASY_FANCYBOX_VERSION.'&no_shipping=0&tax=0&charset=UTF%2d8&currency_code=EUR" title="'.__('Donate to keep the Easy FancyBox plugin development going!','easy-fancybox').'">
66
  <img src="https://www.paypalobjects.com/en_US/i/btn/btn_donate_LG.gif" style="border:none;float:right;margin:5px 0 0 10px" alt="'.__('Donate to keep the Easy FancyBox plugin development going!','easy-fancybox').'" width="92" height="26" /></a>';
77
  Black Friday to Cyber Monday: THE BIG 30 SALE at Status301.
78
  <em>A whopping 30% discount but only for the first 30 customers.
79
  After that, there will still be a discount of 15% for everybody until tuesday 0:00 GMT so
80
+ <strong><a href="https://premium.status301.com/black-friday-til-cyber-monday-big-30-sale/?discount=BFCM30" target="_blank">to take advantage of this opportunity</a></strong>
81
  before it\'s too late</em>...</p>';
82
  }
83
 
87
  _e('Notice: The current Easy FancyBox plugin version is not fully compatible with your version of the Pro extension. Some advanced options may not be functional.','easy-fancybox');
88
  echo ' ';
89
  if ( current_user_can( 'install_plugins' ) )
90
+ printf(__('Please <a href="%1$s" target="_blank">download and install the latest Pro version</a>.','easy-fancybox'), 'https://premium.status301.com/account/');
91
  else
92
  _e('Please contact your web site administrator.','easy-fancybox');
93
  echo '</p>';
95
  }
96
 
97
  // add our FancyBox Media Settings Fields
98
+ public static function settings_fields($args)
99
+ {
100
  $disabled = (isset($args['status']) && 'disabled' == $args['status']) ? ' disabled="disabled"' : '';
101
  if (isset($args['input']))
102
  switch($args['input']) {
185
  /**
186
  * Adds an action link to the Plugins page
187
  */
188
+ public static function add_action_link( $links )
189
+ {
190
  $settings_link = '<a href="' . admin_url('options-media.php') . '">' . translate('Settings') . '</a>';
191
  array_unshift( $links, $settings_link );
192
  return $links;
193
  }
194
 
195
+ /**
196
+ * Adds links to plugin's description
197
+ */
198
+ public static function plugin_meta_links( $links, $file )
199
+ {
200
+ if ( $file == plugin_basename(__FILE__) ) {
201
+ $links[] = '<a target="_blank" href="https://wordpress.org/support/plugin/easy-fancybox/">' . __('Support','easy-fancybox') . '</a>';
202
+ $links[] = '<a target="_blank" href="https://wordpress.org/support/plugin/easy-fancybox/reviews/?filter=5#new-post">' . __('Rate ★★★★★','easy-fancybox') . '</a>';
203
+ }
204
+
205
+ return $links;
206
+ }
207
+
208
  /***
209
  * Santize Callbacks
210
  */
211
 
212
+ public static function intval($setting = '')
213
+ {
214
  if ($setting == '')
215
  return '';
216
 
253
  //echo '<a href="?easy_fancybox_ignore_notice=1" title="' . __('Hide message','easy-fancybox') . '" style="display:block;float:right">X</a>';
254
  _e('Notice: The current Easy FancyBox plugin version is not fully compatible with your version of the Pro extension. Some advanced options may not be functional.','easy-fancybox');
255
  echo '<br />';
256
+ printf(__('Please <a href="%1$s" target="_blank">download and install the latest Pro version</a>.','easy-fancybox'), 'https://premium.status301.com/account/');
257
  echo ' ';
258
  printf(__('Or you can ignore and <a href="%1$s">hide this message</a>.','easy-fancybox'), '?easy_fancybox_ignore_notice=1');
259
  echo '</p></div>';
260
  }
261
  }
262
 
263
+ public static function load_textdomain()
264
+ {
265
  load_plugin_textdomain('easy-fancybox', false, dirname( parent::$plugin_basename ) . '/languages' );
266
  }
267
 
268
+ public static function admin_init()
269
+ {
270
  /* Dismissable notice */
271
  /* If user clicks to ignore the notice, add that to their user meta */
272
  global $current_user;
284
  RUN
285
  **********************/
286
 
287
+ public function __construct()
288
+ {
289
  add_action('plugins_loaded', array(__CLASS__, 'load_textdomain'));
290
  add_action('admin_notices', array(__CLASS__, 'admin_notice'));
291
  add_filter('plugin_action_links_'.parent::$plugin_basename, array(__CLASS__, 'add_action_link') );
inc/class-easyfancybox.php CHANGED
@@ -31,8 +31,8 @@ class easyFancyBox {
31
  MAIN INLINE SCRIPT
32
  **********************/
33
 
34
- private static function main() {
35
-
36
  // check for any enabled sections
37
  foreach ( self::$options['Global']['options']['Enable']['options'] as $value ) {
38
  if ( isset($value['id']) && '1' == get_option($value['id'],$value['default']) ) {
@@ -312,8 +312,8 @@ var easy_fancybox_auto=function(){setTimeout(function(){jQuery(\'a[class*="'.$tr
312
  ACTIONS & FILTERS
313
  ***********************/
314
 
315
- public static function enqueue_scripts() {
316
-
317
  // make sure whe actually need to do anything
318
  if ( !self::$add_scripts )
319
  return;
@@ -385,22 +385,26 @@ var easy_fancybox_auto=function(){setTimeout(function(){jQuery(\'a[class*="'.$tr
385
  }
386
 
387
  // fallback methods for WordPress pre-4.5
388
- public static function print_inline_script() {
 
389
  print( '<script type="text/javascript">' . self::$inline_script . '</script>' );
390
  }
391
 
392
- public static function print_inline_style() {
 
393
  print( '<style id="fancybox-inline-css" type="text/css">' . self::$inline_style . '</style>' );
394
  }
395
 
396
- public static function print_inline_style_ie() {
 
397
  print( '<!--[if lt IE 9]><style id="fancybox-inline-css-ie" type="text/css">' . self::$inline_style_ie . '</style><![endif]-->' );
398
  }
399
 
400
  // Hack to fix missing wmode in Youtube oEmbed code based on David C's code in the comments on
401
  // http://www.mehigh.biz/wordpress/adding-wmode-transparent-to-wordpress-3-media-embeds.html
402
  // without the wmode, videos will float over the light box no matter what z-index is set.
403
- public static function add_video_wmode_opaque($html) {
 
404
  if ( strpos($html, "<embed src=" ) !== false ) {
405
  $html = str_replace('</param><embed', '</param><param name="wmode" value="opaque"></param><embed wmode="opaque"', $html);
406
  } elseif ( strpos($html, 'youtube' ) !== false && strpos($html, 'wmode' ) == false ) {
@@ -413,8 +417,8 @@ var easy_fancybox_auto=function(){setTimeout(function(){jQuery(\'a[class*="'.$tr
413
  return $html;
414
  }
415
 
416
- public static function onready_callback( $content ) {
417
-
418
  $content .= 'jQuery(easy_fancybox_handler);jQuery(document).on(\'' . implode(" ", self::$events) . '\',easy_fancybox_handler);' . PHP_EOL;
419
 
420
  if ( self::$onready_auto )
@@ -423,7 +427,8 @@ var easy_fancybox_auto=function(){setTimeout(function(){jQuery(\'a[class*="'.$tr
423
  return $content;
424
  }
425
 
426
- public static function upgrade( $old_version ) {
 
427
  if ( !$old_version ) { // upgrade from 1.7 or older
428
  if ( 'html' === get_option('fancybox_PDFclassType') ) {
429
  update_option('fancybox_PDFonStart', 'function(selectedArray,selectedIndex,selectedOpts){selectedOpts.type=\'pdf\';}');
@@ -434,21 +439,24 @@ var easy_fancybox_auto=function(){setTimeout(function(){jQuery(\'a[class*="'.$tr
434
  update_option('easy_fancybox_version', EASY_FANCYBOX_VERSION);
435
  }
436
 
437
- public static function load_defaults() {
 
438
  if ( empty(self::$options) ) {
439
  include self::$plugin_dir . '/inc/easyfancybox-options.php';
440
  self::$options = $efb_options;
441
  }
442
  }
443
 
444
- public static function maybe_upgrade() {
 
445
  $version = get_option('easy_fancybox_version', 0);
446
 
447
  if ( version_compare( EASY_FANCYBOX_VERSION, $version, '>' ) )
448
  self::upgrade($version);
449
  }
450
 
451
- public static function load_main() {
 
452
  // Treat settings and prepare inline scripts and styles, or log debug message
453
  if ( self::main() ) {
454
  $priority = get_option( 'fancybox_scriptPriority' );
@@ -456,8 +464,6 @@ var easy_fancybox_auto=function(){setTimeout(function(){jQuery(\'a[class*="'.$tr
456
 
457
  add_action( 'wp_enqueue_scripts', array(__CLASS__,'enqueue_scripts'), self::$priority );
458
  add_filter( 'embed_oembed_html', array(__CLASS__,'add_video_wmode_opaque'), 10 );
459
- } elseif ( defined('WP_DEBUG') && WP_DEBUG ) {
460
- error_log('No active Easy FancyBox media types set.');
461
  }
462
  }
463
 
@@ -465,7 +471,8 @@ var easy_fancybox_auto=function(){setTimeout(function(){jQuery(\'a[class*="'.$tr
465
  RUN
466
  **********************/
467
 
468
- public function __construct( $file ) {
 
469
  // VARS
470
  self::$plugin_url = plugins_url( '/', $file );
471
  self::$plugin_basename = plugin_basename( $file );
31
  MAIN INLINE SCRIPT
32
  **********************/
33
 
34
+ private static function main()
35
+ {
36
  // check for any enabled sections
37
  foreach ( self::$options['Global']['options']['Enable']['options'] as $value ) {
38
  if ( isset($value['id']) && '1' == get_option($value['id'],$value['default']) ) {
312
  ACTIONS & FILTERS
313
  ***********************/
314
 
315
+ public static function enqueue_scripts()
316
+ {
317
  // make sure whe actually need to do anything
318
  if ( !self::$add_scripts )
319
  return;
385
  }
386
 
387
  // fallback methods for WordPress pre-4.5
388
+ public static function print_inline_script()
389
+ {
390
  print( '<script type="text/javascript">' . self::$inline_script . '</script>' );
391
  }
392
 
393
+ public static function print_inline_style()
394
+ {
395
  print( '<style id="fancybox-inline-css" type="text/css">' . self::$inline_style . '</style>' );
396
  }
397
 
398
+ public static function print_inline_style_ie()
399
+ {
400
  print( '<!--[if lt IE 9]><style id="fancybox-inline-css-ie" type="text/css">' . self::$inline_style_ie . '</style><![endif]-->' );
401
  }
402
 
403
  // Hack to fix missing wmode in Youtube oEmbed code based on David C's code in the comments on
404
  // http://www.mehigh.biz/wordpress/adding-wmode-transparent-to-wordpress-3-media-embeds.html
405
  // without the wmode, videos will float over the light box no matter what z-index is set.
406
+ public static function add_video_wmode_opaque($html)
407
+ {
408
  if ( strpos($html, "<embed src=" ) !== false ) {
409
  $html = str_replace('</param><embed', '</param><param name="wmode" value="opaque"></param><embed wmode="opaque"', $html);
410
  } elseif ( strpos($html, 'youtube' ) !== false && strpos($html, 'wmode' ) == false ) {
417
  return $html;
418
  }
419
 
420
+ public static function onready_callback( $content )
421
+ {
422
  $content .= 'jQuery(easy_fancybox_handler);jQuery(document).on(\'' . implode(" ", self::$events) . '\',easy_fancybox_handler);' . PHP_EOL;
423
 
424
  if ( self::$onready_auto )
427
  return $content;
428
  }
429
 
430
+ public static function upgrade( $old_version )
431
+ {
432
  if ( !$old_version ) { // upgrade from 1.7 or older
433
  if ( 'html' === get_option('fancybox_PDFclassType') ) {
434
  update_option('fancybox_PDFonStart', 'function(selectedArray,selectedIndex,selectedOpts){selectedOpts.type=\'pdf\';}');
439
  update_option('easy_fancybox_version', EASY_FANCYBOX_VERSION);
440
  }
441
 
442
+ public static function load_defaults()
443
+ {
444
  if ( empty(self::$options) ) {
445
  include self::$plugin_dir . '/inc/easyfancybox-options.php';
446
  self::$options = $efb_options;
447
  }
448
  }
449
 
450
+ public static function maybe_upgrade()
451
+ {
452
  $version = get_option('easy_fancybox_version', 0);
453
 
454
  if ( version_compare( EASY_FANCYBOX_VERSION, $version, '>' ) )
455
  self::upgrade($version);
456
  }
457
 
458
+ public static function load_main()
459
+ {
460
  // Treat settings and prepare inline scripts and styles, or log debug message
461
  if ( self::main() ) {
462
  $priority = get_option( 'fancybox_scriptPriority' );
464
 
465
  add_action( 'wp_enqueue_scripts', array(__CLASS__,'enqueue_scripts'), self::$priority );
466
  add_filter( 'embed_oembed_html', array(__CLASS__,'add_video_wmode_opaque'), 10 );
 
 
467
  }
468
  }
469
 
471
  RUN
472
  **********************/
473
 
474
+ public function __construct( $file )
475
+ {
476
  // VARS
477
  self::$plugin_url = plugins_url( '/', $file );
478
  self::$plugin_basename = plugin_basename( $file );
inc/easyfancybox-options.php CHANGED
@@ -2,7 +2,7 @@
2
  /**
3
  * Easy FancyBox options and their defaults array
4
  */
5
- $efb_url = "https://premium.status301.net/downloads/easy-fancybox-pro/";
6
 
7
  $efb_options = array (
8
  'Global' => array(
2
  /**
3
  * Easy FancyBox options and their defaults array
4
  */
5
+ $efb_url = "https://premium.status301.com/downloads/easy-fancybox-pro/";
6
 
7
  $efb_options = array (
8
  'Global' => array(
languages/easy-fancybox-cs_CZ.mo CHANGED
File without changes
languages/easy-fancybox-cs_CZ.po CHANGED
File without changes
languages/easy-fancybox-es_ES.mo CHANGED
File without changes
languages/easy-fancybox-es_ES.po CHANGED
File without changes
languages/easy-fancybox-fa_IR.mo CHANGED
File without changes
languages/easy-fancybox-fa_IR.po CHANGED
File without changes
languages/easy-fancybox-fr_FR.mo CHANGED
File without changes
languages/easy-fancybox-fr_FR.po CHANGED
File without changes
languages/easy-fancybox-hi_IN.mo CHANGED
File without changes
languages/easy-fancybox-hi_IN.po CHANGED
File without changes
languages/easy-fancybox-hr.mo CHANGED
File without changes
languages/easy-fancybox-hr.po CHANGED
File without changes
languages/easy-fancybox-id_ID.mo CHANGED
File without changes
languages/easy-fancybox-id_ID.po CHANGED
File without changes
languages/easy-fancybox-lt_LT.mo CHANGED
File without changes
languages/easy-fancybox-lt_LT.po CHANGED
File without changes
languages/easy-fancybox-pl_PL.mo CHANGED
File without changes
languages/easy-fancybox-pl_PL.po CHANGED
File without changes
languages/easy-fancybox-readme-bel.po CHANGED
@@ -253,8 +253,8 @@ msgid "Tweak the value 641 to target other screen sizes."
253
  msgstr "Tweak значэнне 641 у дачыненнi да iншых памераў экрана."
254
 
255
  #. Found in faq paragraph.
256
- msgid "In the <a href=\"http://premium.status301.net/downloads/easy-fancybox-pro/\">Pro extension</a>, there is an Advanced option called \"Gallery Auto-rotation\" for that."
257
- msgstr "У <a href=\"http://premium.status301.net/downloads/easy-fancybox-pro/\">Pro пашырэннея</a>для гэтага ёсць пашыраны варыянт пад назвай \"Галерэя Аўтаратацыі\"."
258
 
259
  #. Found in faq paragraph.
260
  msgid "Yes. All links with class <strong>nolightbox</strong> that would normally get auto-enabled, will be excluded from opening in a FancyBox overlay."
@@ -361,8 +361,8 @@ msgid "FancyBox tries to detect the size of the content automatically but if it
361
  msgstr "FancyBox спрабуе вызначыць памер змесціва аўтаматычна, але калі ён не можа знайсці памер, па змаўчанні будзе выкарыстоўвацца налады для канкрэтнага тыпу кантэнту, якая ўсталяваная на Налады>Медыя-старонка."
362
 
363
  #. Found in faq paragraph.
364
- msgid "The <strong><a href=\"http://premium.status301.net/downloads/easy-fancybox-pro/\">Pro extension</a></strong> provides an extra option to allow you to manually override this by defining the width and height wrapped in curly brases in the class attribute of the link itself. Make sure the option \"Inlcude the Metadata jQuery extension script...\" under FancyBox | Links on Settings &gt; Media is enabled."
365
- msgstr "<strong><a href=\"http://premium.status301.net/downloads/easy-fancybox-pro/\">Pro пашырэнне</a></strong> забяспечвае дадатковы параметр, каб дазволіць вам ўручную перавызначыць значэння шырыні і вышыні, абгорнутыz ў фігурныя дужкі ў атрыбуце класа самой спасылкі. Пераканайцеся, што опцыя \"Уключаць пашырэнне сцэнара Metadata jQuery ...\" пад FancyBox|Спасылкі на Налады>Медыя ўключана."
366
 
367
  #. Found in faq paragraph.
368
  msgid "For example, a Flash movie with different size:"
@@ -833,8 +833,8 @@ msgid "<strong>Also supports:</strong>"
833
  msgstr "<strong>Таксама падтрымлівае:</strong>"
834
 
835
  #. Found in description paragraph.
836
- msgid "For <strong>advanced options</strong> and <strong>priority support</strong>, there is a <strong><a href=\"http://premium.status301.net/downloads/easy-fancybox-pro/\">Pro extension</a></strong> available."
837
- msgstr "Для <strong>Дадатковыя параметры</strong> і <strong>прыярытэтная падтрымка</strong>, ёсць даступнае<strong><a href=\"http://premium.status301.net/downloads/easy-fancybox-pro/\">Pro пашырэнне</a></strong>."
838
 
839
  #. Found in description paragraph.
840
  msgid "See <a href=\"http://wordpress.org/plugins/easy-fancybox/screenshots/\">Screenshots</a> for an impression on how images and YouTube movies will be presented on your site as soon as you have installed and (network) activated this simple plugin."
253
  msgstr "Tweak значэнне 641 у дачыненнi да iншых памераў экрана."
254
 
255
  #. Found in faq paragraph.
256
+ msgid "In the <a href=\"http://premium.status301.com/downloads/easy-fancybox-pro/\">Pro extension</a>, there is an Advanced option called \"Gallery Auto-rotation\" for that."
257
+ msgstr "У <a href=\"http://premium.status301.com/downloads/easy-fancybox-pro/\">Pro пашырэннея</a>для гэтага ёсць пашыраны варыянт пад назвай \"Галерэя Аўтаратацыі\"."
258
 
259
  #. Found in faq paragraph.
260
  msgid "Yes. All links with class <strong>nolightbox</strong> that would normally get auto-enabled, will be excluded from opening in a FancyBox overlay."
361
  msgstr "FancyBox спрабуе вызначыць памер змесціва аўтаматычна, але калі ён не можа знайсці памер, па змаўчанні будзе выкарыстоўвацца налады для канкрэтнага тыпу кантэнту, якая ўсталяваная на Налады>Медыя-старонка."
362
 
363
  #. Found in faq paragraph.
364
+ msgid "The <strong><a href=\"http://premium.status301.com/downloads/easy-fancybox-pro/\">Pro extension</a></strong> provides an extra option to allow you to manually override this by defining the width and height wrapped in curly brases in the class attribute of the link itself. Make sure the option \"Inlcude the Metadata jQuery extension script...\" under FancyBox | Links on Settings &gt; Media is enabled."
365
+ msgstr "<strong><a href=\"http://premium.status301.com/downloads/easy-fancybox-pro/\">Pro пашырэнне</a></strong> забяспечвае дадатковы параметр, каб дазволіць вам ўручную перавызначыць значэння шырыні і вышыні, абгорнутыz ў фігурныя дужкі ў атрыбуце класа самой спасылкі. Пераканайцеся, што опцыя \"Уключаць пашырэнне сцэнара Metadata jQuery ...\" пад FancyBox|Спасылкі на Налады>Медыя ўключана."
366
 
367
  #. Found in faq paragraph.
368
  msgid "For example, a Flash movie with different size:"
833
  msgstr "<strong>Таксама падтрымлівае:</strong>"
834
 
835
  #. Found in description paragraph.
836
+ msgid "For <strong>advanced options</strong> and <strong>priority support</strong>, there is a <strong><a href=\"http://premium.status301.com/downloads/easy-fancybox-pro/\">Pro extension</a></strong> available."
837
+ msgstr "Для <strong>Дадатковыя параметры</strong> і <strong>прыярытэтная падтрымка</strong>, ёсць даступнае<strong><a href=\"http://premium.status301.com/downloads/easy-fancybox-pro/\">Pro пашырэнне</a></strong>."
838
 
839
  #. Found in description paragraph.
840
  msgid "See <a href=\"http://wordpress.org/plugins/easy-fancybox/screenshots/\">Screenshots</a> for an impression on how images and YouTube movies will be presented on your site as soon as you have installed and (network) activated this simple plugin."
languages/easy-fancybox-ro_RO.po CHANGED
File without changes
languages/easy-fancybox-sr_RS.mo CHANGED
File without changes
languages/easy-fancybox-sr_RS.po CHANGED
File without changes
languages/easy-fancybox-tr_TR.mo CHANGED
File without changes
languages/easy-fancybox-tr_TR.po CHANGED
File without changes
languages/easy-fancybox-ua_UA.mo CHANGED
File without changes
languages/easy-fancybox-ua_UA.po CHANGED
File without changes
languages/instructions.txt CHANGED
File without changes
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=ravan
4
  Tags: fancybox, lightbox, gallery, image, photo, video, flash, overlay, youtube, vimeo, dailymotion, pdf, svg, iframe, swf, jquery, webp
5
  Requires at least: 3.3
6
  Tested up to: 5.2
7
- Stable tag: 1.8.16
8
 
9
  Easily enable the FancyBox jQuery extension on just about all media links. Multi-Site compatible. Supports iFrame and Flash movies.
10
 
@@ -47,7 +47,7 @@ Additional features:
47
  - Fade or Elastic popup effects
48
  - Styling options for light box overlay (color and opacity) and window (border size and color)
49
 
50
- For **advanced options** and **priority support**, there is a **[Pro extension](https://premium.status301.net/downloads/easy-fancybox-pro/)** available. See Pro features below.
51
 
52
  See [FAQ's](https://wordpress.org/plugins/easy-fancybox/#faq) for instructions to manage YouTube, Dailymotion and Vimeo movies (and similar services) and tips to make inline content display in a FancyBox overlay.
53
 
@@ -68,7 +68,7 @@ Visit [FancyBox](http://fancybox.net/) for more information and examples.
68
  - Show/hide image title on mouse hover
69
  - Fine-tune media link and gallery autodetection to match your theme source markup to allow galleries per post for example
70
 
71
- For these additional features, you need to install the **[Pro extension](https://premium.status301.net/downloads/easy-fancybox-pro/)** alongside this free plugin.
72
 
73
 
74
  = Contribute =
@@ -81,7 +81,7 @@ If you wish to help build this plugin, you're very welcome to [translate Easy Fa
81
 
82
  = General =
83
 
84
- - **Outbound links or Downloads tracking** in some of the stats plugins can interfere with FancyBox. Disable such option or exclude links manually with a class (see instructions for SlimStat below)
85
  - Most plugins and themes that already include a light box script. Continue reading to see if you are using one of the know ones or follow the troubleshooting steps to find out what is conflicting on your site.
86
  - Any theme that is missing the obligatory `<?php wp_footer(); ?>` call in the footer.php template.
87
  - When showing an iframe as inline content in FancyBox -- not advised, use fancybox-iframe instead! -- the iframe will become blank after opening and closing it. The solution is to link directly to the iframe source and use `class="fancybox-iframe"` instead.
@@ -90,8 +90,7 @@ If you wish to help build this plugin, you're very welcome to [translate Easy Fa
90
  = Plugin conflicts =
91
 
92
  - **jQuery Updater** moves jQuery to version 2+ which is incompatible.
93
- - **All in One SEO Pack** and **Analytics for WordPress** with outbound link tracking enabled. Disable that feature.
94
- - **WP Slimstat** with Track Outbound Clicks enabled, will break the light box effect on some browsers. Adding `fancybox` (or any of the other classes like `fancybox-youtube,fancybox-iframe,fancybox-inline` depending on which media should be displayed in FancyBox) to the Do Not Track field is reported to solve the issue. Slimstat also might interfere with the YouTube url conversion. When clicking a Youtube link, the movie opens in an overlay as it is supposed to but immediately after that, the complete page gets redirected to the original YouTube page. Adding a `class="noslimstat"` to the link is reported to work around the issue.
95
  - **Google Analytics for WordPress** converts links like `href="#anyID"` to `href="http://yoursite.url/page/#anyID"`, disabling inline content shown in FancyBox.
96
  - Both the **uBillBoard** and **Camera slideshow** have their own easing script hard-coded which conflicts with the one in Easy FancyBox. The only way around the conflict is to set both the Easing In and Easing Out options on your Settings > Media page to **Swing**.
97
  - **Wordpress Firewall 2** blocks access to image files needed for proper display of the FancyBox overlay in older IE and other non-css3 browsers.
@@ -181,7 +180,7 @@ The original FancyBox 1.3.4 script was not developed with mobile devices in mind
181
 
182
  = Can I make a slideshow from my gallery? =
183
 
184
- In the [Pro extension](https://premium.status301.net/downloads/easy-fancybox-pro/), there is an Advanced option called "Gallery Auto-rotation" for that.
185
 
186
 
187
  = Can I exclude images or other links from auto-attribution? =
@@ -336,7 +335,7 @@ If you don't have *Auto-detect* checked under **SWF** on Settings > Media admin
336
 
337
  FancyBox tries to detect the size of the content automatically but if it can not find a size, it will default to the settings for that particular content type as set on the Settings > Media page.
338
 
339
- The **[Pro extension](https://premium.status301.net/downloads/easy-fancybox-pro/)** provides an extra option to allow you to manually override this by defining the width and height wrapped in curly braces in the class attribute of the link itself. Make sure the option "Include the Metadata jQuery extension script..." under FancyBox | Miscellaneous | Advanced on Settings > Media is enabled.
340
 
341
  For example, a Flash movie with different size:
342
 
@@ -495,12 +494,18 @@ If you still do not get to see your images in FancyBox, ask on the [Easy FancyBo
495
  == Upgrade Notice ==
496
 
497
  = 1.8.17 =
 
498
 
499
 
500
  == Changelog ==
501
 
 
 
 
 
502
  = 1.8.17 =
503
- *
 
504
 
505
  = 1.8.16 =
506
  * FIX: Trying to get property 'ID' of non-object
4
  Tags: fancybox, lightbox, gallery, image, photo, video, flash, overlay, youtube, vimeo, dailymotion, pdf, svg, iframe, swf, jquery, webp
5
  Requires at least: 3.3
6
  Tested up to: 5.2
7
+ Stable tag: 1.8.17
8
 
9
  Easily enable the FancyBox jQuery extension on just about all media links. Multi-Site compatible. Supports iFrame and Flash movies.
10
 
47
  - Fade or Elastic popup effects
48
  - Styling options for light box overlay (color and opacity) and window (border size and color)
49
 
50
+ For **advanced options** and **priority support**, there is a **[Pro extension](https://premium.status301.com/downloads/easy-fancybox-pro/)** available. See Pro features below.
51
 
52
  See [FAQ's](https://wordpress.org/plugins/easy-fancybox/#faq) for instructions to manage YouTube, Dailymotion and Vimeo movies (and similar services) and tips to make inline content display in a FancyBox overlay.
53
 
68
  - Show/hide image title on mouse hover
69
  - Fine-tune media link and gallery autodetection to match your theme source markup to allow galleries per post for example
70
 
71
+ For these additional features, you need to install the **[Pro extension](https://premium.status301.com/downloads/easy-fancybox-pro/)** alongside this free plugin.
72
 
73
 
74
  = Contribute =
81
 
82
  = General =
83
 
84
+ - **Outbound click or Download tracking** in some of the stats plugins can interfere with FancyBox. Disable such options or exclude links manually with a class if possible (see instructions for SlimStat below)
85
  - Most plugins and themes that already include a light box script. Continue reading to see if you are using one of the know ones or follow the troubleshooting steps to find out what is conflicting on your site.
86
  - Any theme that is missing the obligatory `<?php wp_footer(); ?>` call in the footer.php template.
87
  - When showing an iframe as inline content in FancyBox -- not advised, use fancybox-iframe instead! -- the iframe will become blank after opening and closing it. The solution is to link directly to the iframe source and use `class="fancybox-iframe"` instead.
90
  = Plugin conflicts =
91
 
92
  - **jQuery Updater** moves jQuery to version 2+ which is incompatible.
93
+ - **WP Slimstat** and **Matomo/Piwik** with Track Outbound Clicks enabled, will break the light box effect on some browsers. Adding `fancybox` (or any of the other classes like `fancybox-youtube,fancybox-iframe,fancybox-inline` depending on which media should be displayed in FancyBox) to the Do Not Track field is reported to solve the issue. Slimstat also might interfere with the YouTube url conversion. When clicking a Youtube link, the movie opens in an overlay as it is supposed to but immediately after that, the complete page gets redirected to the original YouTube page. Adding a `class="noslimstat"` to the link is reported to work around the issue.
 
94
  - **Google Analytics for WordPress** converts links like `href="#anyID"` to `href="http://yoursite.url/page/#anyID"`, disabling inline content shown in FancyBox.
95
  - Both the **uBillBoard** and **Camera slideshow** have their own easing script hard-coded which conflicts with the one in Easy FancyBox. The only way around the conflict is to set both the Easing In and Easing Out options on your Settings > Media page to **Swing**.
96
  - **Wordpress Firewall 2** blocks access to image files needed for proper display of the FancyBox overlay in older IE and other non-css3 browsers.
180
 
181
  = Can I make a slideshow from my gallery? =
182
 
183
+ In the [Pro extension](https://premium.status301.com/downloads/easy-fancybox-pro/), there is an Advanced option called "Gallery Auto-rotation" for that.
184
 
185
 
186
  = Can I exclude images or other links from auto-attribution? =
335
 
336
  FancyBox tries to detect the size of the content automatically but if it can not find a size, it will default to the settings for that particular content type as set on the Settings > Media page.
337
 
338
+ The **[Pro extension](https://premium.status301.com/downloads/easy-fancybox-pro/)** provides an extra option to allow you to manually override this by defining the width and height wrapped in curly braces in the class attribute of the link itself. Make sure the option "Include the Metadata jQuery extension script..." under FancyBox | Miscellaneous | Advanced on Settings > Media is enabled.
339
 
340
  For example, a Flash movie with different size:
341
 
494
  == Upgrade Notice ==
495
 
496
  = 1.8.17 =
497
+ Fix compat messages and links
498
 
499
 
500
  == Changelog ==
501
 
502
+ = 1.8.18 =
503
+ * FIX: Jetpack Tiled Gallery block compatibility
504
+ * Don't include mousewheel script by default
505
+
506
  = 1.8.17 =
507
+ * Pro compatibility messages
508
+ * Support forum link
509
 
510
  = 1.8.16 =
511
  * FIX: Trying to get property 'ID' of non-object