Easy FancyBox - Version 1.8.5

Version Description

Bugfix release: prevent Inline content title.

=

Download this release

Release Info

Developer RavanH
Plugin Icon 128x128 Easy FancyBox
Version 1.8.5
Comparing to
See all releases

Code changes from version 1.8.2 to 1.8.5

easy-fancybox.php CHANGED
@@ -5,7 +5,7 @@ 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.2
9
  Author: RavanH
10
  Author URI: http://status301.net/
11
  */
@@ -37,8 +37,8 @@ if ( ! defined( 'ABSPATH' ) ) exit;
37
  * CONSTANTS
38
  **************/
39
 
40
- define( 'EASY_FANCYBOX_VERSION', '1.8.2' );
41
- define( 'FANCYBOX_VERSION', '1.3.16' );
42
  define( 'MOUSEWHEEL_VERSION', '3.1.13' );
43
  define( 'EASING_VERSION', '1.4.1' );
44
  define( 'METADATA_VERSION', '2.22.1' );
@@ -48,9 +48,9 @@ define( 'METADATA_VERSION', '2.22.1' );
48
  **************/
49
 
50
  require_once dirname( __FILE__ ) . '/inc/class-easyfancybox.php';
51
- $efb = new easyFancyBox( __FILE__ );
52
 
53
  if ( is_admin() ) {
54
  require_once dirname( __FILE__ ) . '/inc/class-easyfancybox-admin.php';
55
- $efb_admin = new easyFancyBox_Admin();
56
  }
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.5
9
  Author: RavanH
10
  Author URI: http://status301.net/
11
  */
37
  * CONSTANTS
38
  **************/
39
 
40
+ define( 'EASY_FANCYBOX_VERSION', '1.8.5' );
41
+ define( 'FANCYBOX_VERSION', '1.3.20' );
42
  define( 'MOUSEWHEEL_VERSION', '3.1.13' );
43
  define( 'EASING_VERSION', '1.4.1' );
44
  define( 'METADATA_VERSION', '2.22.1' );
48
  **************/
49
 
50
  require_once dirname( __FILE__ ) . '/inc/class-easyfancybox.php';
51
+ new easyFancyBox( __FILE__ );
52
 
53
  if ( is_admin() ) {
54
  require_once dirname( __FILE__ ) . '/inc/class-easyfancybox-admin.php';
55
+ new easyFancyBox_Admin();
56
  }
fancybox/jquery.fancybox.css CHANGED
@@ -7,7 +7,7 @@
7
  * Copyright (c) 2008 - 2010 Janis Skarnelis
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
- * Version: 1.3.14 (23/04/2018)
11
  *
12
  * Dual licensed under the MIT and GPL licenses:
13
  * http://www.opensource.org/licenses/mit-license.php
@@ -223,6 +223,11 @@
223
  right:-9999px
224
  }
225
 
 
 
 
 
 
226
  #fancybox-left:hover span {
227
  left: 20px;
228
  }
7
  * Copyright (c) 2008 - 2010 Janis Skarnelis
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
+ * Version: 1.3.17 (2018/05/12)
11
  *
12
  * Dual licensed under the MIT and GPL licenses:
13
  * http://www.opensource.org/licenses/mit-license.php
223
  right:-9999px
224
  }
225
 
226
+ #fancybox-left:focus, #fancybox-right:focus {
227
+ outline: none;
228
+ background: initial;
229
+ }
230
+
231
  #fancybox-left:hover span {
232
  left: 20px;
233
  }
fancybox/jquery.fancybox.js CHANGED
@@ -7,7 +7,7 @@
7
  * Copyright (c) 2008 - 2010 Janis Skarnelis
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
- * Version: 1.3.16 (2018/05/03)
11
  * Requires: jQuery v1.7+
12
  *
13
  * Dual licensed under the MIT and GPL licenses:
@@ -86,6 +86,10 @@
86
  return;
87
  }
88
 
 
 
 
 
89
  ret = selectedOpts.onStart(selectedArray, selectedIndex, selectedOpts);
90
 
91
  if (ret === false) {
@@ -329,8 +333,7 @@
329
  },
330
 
331
  _process_inline = function() {
332
- var
333
- w = selectedOpts.width,
334
  h = selectedOpts.height,
335
  ww = $(window).width() == 0 ? window.innerWidth : $(window).width(),
336
  wh = $(window).height() == 0 ? window.innerHeight : $(window).height();
@@ -506,7 +509,7 @@
506
  content
507
  .css({
508
  'width' : final_pos.width - currentOpts.padding * 2,
509
- 'height' : selectedOpts.autoDimensions ? 'auto' : final_pos.height - titleHeight - currentOpts.padding * 2
510
  })
511
  .html( tmp.contents() );
512
 
@@ -680,7 +683,7 @@
680
 
681
  if (currentOpts.type == 'iframe') {
682
  $('<iframe id="fancybox-frame" name="fancybox-frame' + new Date().getTime() + '"' + (navigator.userAgent.match(/msie [6]/i) ? ' allowtransparency="true""' : '')
683
- + ' style="border:0;margin:0;overflow:' + (selectedOpts.scrolling == 'auto' ? 'auto' : (selectedOpts.scrolling == 'yes' ? 'scroll' : 'hidden')) + '" src="'
684
  + currentOpts.href + '"' + (false === currentOpts.allowfullscreen ? '' : ' allowfullscreen') + ' allow="autoplay; encrypted-media" tabindex="999"></iframe>')
685
  .appendTo(content).load(function() {
686
  $.fancybox.hideActivity();
@@ -790,13 +793,16 @@
790
  window.innerWidth || document.documentElement.clientWidth || document.getElementsByTagName('body')[0].clientWidth,
791
  h = !isTouch && window.innerHeight && document.documentElement.clientHeight ?
792
  Math.min(window.innerHeight, document.documentElement.clientHeight) :
793
- window.innerHeight || document.documentElement.clientHeight || document.getElementsByTagName('body')[0].clientHeight;
 
 
 
794
 
795
  return [
796
- w - (currentOpts.margin * 2),
797
- h - (currentOpts.margin * 2),
798
- $(document).scrollLeft() + currentOpts.margin,
799
- $(document).scrollTop() + currentOpts.margin
800
  ];
801
  },
802
 
@@ -912,8 +918,6 @@
912
  .data('fancybox', $.extend({}, options, ($.metadata ? $(this).metadata() : {})))
913
  .off('click.fb')
914
  .on('click.fb', function(e) {
915
- e.preventDefault();
916
-
917
  if (busy) {
918
  return;
919
  }
@@ -934,7 +938,7 @@
934
  selectedIndex = selectedArray.index( this );
935
  }
936
 
937
- _start();
938
 
939
  return;
940
  });
@@ -1213,9 +1217,9 @@
1213
  }
1214
 
1215
  align = arguments[0] === true ? 1 : 0;
1216
- view = _get_viewport();
1217
 
1218
- if (!align && (wrap.width() > view[0] || wrap.height() > view[1])) {
1219
  return;
1220
  }
1221
 
7
  * Copyright (c) 2008 - 2010 Janis Skarnelis
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
+ * Version: 1.3.20 (2018/06/15)
11
  * Requires: jQuery v1.7+
12
  *
13
  * Dual licensed under the MIT and GPL licenses:
86
  return;
87
  }
88
 
89
+ if ('object' === typeof arguments[0] && 'click' === arguments[0].type) {
90
+ arguments[0].preventDefault();
91
+ }
92
+
93
  ret = selectedOpts.onStart(selectedArray, selectedIndex, selectedOpts);
94
 
95
  if (ret === false) {
333
  },
334
 
335
  _process_inline = function() {
336
+ var w = selectedOpts.width,
 
337
  h = selectedOpts.height,
338
  ww = $(window).width() == 0 ? window.innerWidth : $(window).width(),
339
  wh = $(window).height() == 0 ? window.innerHeight : $(window).height();
509
  content
510
  .css({
511
  'width' : final_pos.width - currentOpts.padding * 2,
512
+ 'height' : currentOpts.autoDimensions ? 'auto' : final_pos.height - titleHeight - currentOpts.padding * 2
513
  })
514
  .html( tmp.contents() );
515
 
683
 
684
  if (currentOpts.type == 'iframe') {
685
  $('<iframe id="fancybox-frame" name="fancybox-frame' + new Date().getTime() + '"' + (navigator.userAgent.match(/msie [6]/i) ? ' allowtransparency="true""' : '')
686
+ + ' style="border:0;margin:0;overflow:' + (currentOpts.scrolling == 'auto' ? 'auto' : (currentOpts.scrolling == 'yes' ? 'scroll' : 'hidden')) + '" src="'
687
  + currentOpts.href + '"' + (false === currentOpts.allowfullscreen ? '' : ' allowfullscreen') + ' allow="autoplay; encrypted-media" tabindex="999"></iframe>')
688
  .appendTo(content).load(function() {
689
  $.fancybox.hideActivity();
793
  window.innerWidth || document.documentElement.clientWidth || document.getElementsByTagName('body')[0].clientWidth,
794
  h = !isTouch && window.innerHeight && document.documentElement.clientHeight ?
795
  Math.min(window.innerHeight, document.documentElement.clientHeight) :
796
+ window.innerHeight || document.documentElement.clientHeight || document.getElementsByTagName('body')[0].clientHeight,
797
+ margin;
798
+
799
+ margin = arguments[0] === true ? 0 : currentOpts.margin;
800
 
801
  return [
802
+ w - (margin * 2),
803
+ h - (margin * 2),
804
+ $(document).scrollLeft() + margin,
805
+ $(document).scrollTop() + margin
806
  ];
807
  },
808
 
918
  .data('fancybox', $.extend({}, options, ($.metadata ? $(this).metadata() : {})))
919
  .off('click.fb')
920
  .on('click.fb', function(e) {
 
 
921
  if (busy) {
922
  return;
923
  }
938
  selectedIndex = selectedArray.index( this );
939
  }
940
 
941
+ _start(e);
942
 
943
  return;
944
  });
1217
  }
1218
 
1219
  align = arguments[0] === true ? 1 : 0;
1220
+ view = _get_viewport(true);
1221
 
1222
+ if (!align && ((wrap.width() + 40) > view[0] || (wrap.height() + 40) > view[1])) {
1223
  return;
1224
  }
1225
 
fancybox/jquery.fancybox.min.css CHANGED
@@ -1 +1 @@
1
- #fancybox-loading,#fancybox-loading div,#fancybox-overlay,#fancybox-wrap,.fancybox-bg,#fancybox-outer,#fancybox-content,#fancybox-content>div,#fancybox-content>div>div,#fancybox-frame,#fancybox-close,#fancybox-title,#fancybox-title div,#fancybox-left,#fancybox-right,.fancy-ico{box-sizing:content-box;-moz-box-sizing:content-box}#fancybox-loading{position:fixed;top:50%;left:50%;width:40px;height:40px;margin-top:-20px;margin-left:-20px;cursor:pointer;overflow:hidden;z-index:111104;display:none}#fancybox-loading div{position:absolute;top:0;left:0;width:40px;height:480px;background-image:url('fancybox.png')}#fancybox-overlay{position:absolute;top:0;left:0;width:100%;z-index:111100;display:none}#fancybox-tmp{padding:0;margin:0;border:0;overflow:auto;display:none}#fancybox-wrap{position:absolute;top:0;left:0;padding:20px;z-index:111101;display:none}#fancybox-outer{position:relative;width:100%;height:100%;background:#fff;box-shadow:0 0 20px #111;-moz-box-shadow:0 0 20px #111;-webkit-box-shadow:0 0 20px #111}#fancybox-content{width:0;height:0;padding:0;position:relative;-webkit-overflow-scrolling:touch;overflow-y:auto;z-index:111102;border:0 solid #fff;background:#fff;-moz-background-clip:padding;-webkit-background-clip:padding;background-clip:padding-box}#fancybox-content>div{max-width:100%;max-height:100%}#fancybox-hide-sel-frame{position:absolute;top:0;left:0;width:100%;height:100%;background:transparent;z-index:111101}#fancybox-close{position:absolute;top:-15px;right:-15px;width:30px;height:30px;background:transparent url('fancybox.png') -40px 0;cursor:pointer;z-index:111103;display:none}#fancybox-error{color:#444;padding:14px;margin:0}#fancybox-frame,#fancybox-img{width:100%;height:100%;border:0}#fancybox-img{padding:0;margin:0;line-height:0;vertical-align:top;max-width:none!important;max-height:none!important}#fancybox-frame{display:block;width:100%;height:100%;z-index:0;-webkit-transform:translateZ(0px);-webkit-transform:translate3d(0,0,0);-webkit-perspective:1000}#fancybox-left,#fancybox-right{position:absolute;bottom:0;height:100%;width:35%;cursor:pointer;background:initial;z-index:111102;display:none}#fancybox-left{left:0}.rtl #fancybox-left{left:auto;right:0}#fancybox-right{right:0}.rtl #fancybox-right{left:0;right:auto}#fancybox-left-ico,#fancybox-right-ico{position:absolute;top:50%;left:-9999px;width:30px;height:30px;margin-top:-15px;cursor:pointer;z-index:111102;display:block}#fancybox-left-ico{background-image:url('fancybox.png');background-position:-40px -30px}.rtl #fancybox-left-ico{background-position:-40px -60px;right:-9999px}#fancybox-right-ico{background-image:url('fancybox.png');background-position:-40px -60px}.rtl #fancybox-right-ico{background-position:-40px -30px;right:-9999px}#fancybox-left:hover span{left:20px}.rtl #fancybox-left:hover span{right:20px}#fancybox-right:hover span{left:auto;right:20px}.rtl #fancybox-right:hover span{right:auto;left:20px}#fancybox-title{z-index:111102}.fancybox-title-inside{padding-bottom:10px;text-align:center;color:#333;position:relative}.fancybox-title-outside{padding-top:10px;color:#fff;font-weight:600}.fancybox-title-over{position:absolute;bottom:0;left:0;color:#FFF;text-align:left}.rtl .fancybox-title-over{text-align:right}#fancybox-title-over{padding:10px;background:rgba(0,0,0,.64);display:block}.fancybox-title-float{position:absolute;left:0;bottom:-20px;height:32px}#fancybox-title-float-wrap{border:0;border-collapse:collapse;width:auto}#fancybox-title-float-wrap tr,#fancybox-title-float-wrap td{border:0;white-space:nowrap}#fancybox-title-float-left{padding:0 0 0 15px;background:url('fancybox.png') -40px -90px no-repeat}#fancybox-title-float-main{color:#fff;line-height:29px;font-weight:600;font-size:14px;padding:0 0 3px 0;background:url('fancybox-x.png') 0 -40px}#fancybox-title-float-right{padding:0 0 0 15px;background:url('fancybox.png') -55px -90px no-repeat}.fancybox-hidden{display:none}
1
+ #fancybox-loading,#fancybox-loading div,#fancybox-overlay,#fancybox-wrap,.fancybox-bg,#fancybox-outer,#fancybox-content,#fancybox-content>div,#fancybox-content>div>div,#fancybox-frame,#fancybox-close,#fancybox-title,#fancybox-title div,#fancybox-left,#fancybox-right,.fancy-ico{box-sizing:content-box;-moz-box-sizing:content-box}#fancybox-loading{position:fixed;top:50%;left:50%;width:40px;height:40px;margin-top:-20px;margin-left:-20px;cursor:pointer;overflow:hidden;z-index:111104;display:none}#fancybox-loading div{position:absolute;top:0;left:0;width:40px;height:480px;background-image:url('fancybox.png')}#fancybox-overlay{position:absolute;top:0;left:0;width:100%;z-index:111100;display:none}#fancybox-tmp{padding:0;margin:0;border:0;overflow:auto;display:none}#fancybox-wrap{position:absolute;top:0;left:0;padding:20px;z-index:111101;display:none}#fancybox-outer{position:relative;width:100%;height:100%;background:#fff;box-shadow:0 0 20px #111;-moz-box-shadow:0 0 20px #111;-webkit-box-shadow:0 0 20px #111}#fancybox-content{width:0;height:0;padding:0;position:relative;-webkit-overflow-scrolling:touch;overflow-y:auto;z-index:111102;border:0 solid #fff;background:#fff;-moz-background-clip:padding;-webkit-background-clip:padding;background-clip:padding-box}#fancybox-content>div{max-width:100%;max-height:100%}#fancybox-hide-sel-frame{position:absolute;top:0;left:0;width:100%;height:100%;background:transparent;z-index:111101}#fancybox-close{position:absolute;top:-15px;right:-15px;width:30px;height:30px;background:transparent url('fancybox.png') -40px 0;cursor:pointer;z-index:111103;display:none}#fancybox-error{color:#444;padding:14px;margin:0}#fancybox-frame,#fancybox-img{width:100%;height:100%;border:0}#fancybox-img{padding:0;margin:0;line-height:0;vertical-align:top;max-width:none!important;max-height:none!important}#fancybox-frame{display:block;width:100%;height:100%;z-index:0;-webkit-transform:translateZ(0px);-webkit-transform:translate3d(0,0,0);-webkit-perspective:1000}#fancybox-left,#fancybox-right{position:absolute;bottom:0;height:100%;width:35%;cursor:pointer;background:initial;z-index:111102;display:none}#fancybox-left{left:0}.rtl #fancybox-left{left:auto;right:0}#fancybox-right{right:0}.rtl #fancybox-right{left:0;right:auto}#fancybox-left-ico,#fancybox-right-ico{position:absolute;top:50%;left:-9999px;width:30px;height:30px;margin-top:-15px;cursor:pointer;z-index:111102;display:block}#fancybox-left-ico{background-image:url('fancybox.png');background-position:-40px -30px}.rtl #fancybox-left-ico{background-position:-40px -60px;right:-9999px}#fancybox-right-ico{background-image:url('fancybox.png');background-position:-40px -60px}.rtl #fancybox-right-ico{background-position:-40px -30px;right:-9999px}#fancybox-left:focus,#fancybox-right:focus{outline:0;background:initial}#fancybox-left:hover span{left:20px}.rtl #fancybox-left:hover span{right:20px}#fancybox-right:hover span{left:auto;right:20px}.rtl #fancybox-right:hover span{right:auto;left:20px}#fancybox-title{z-index:111102}.fancybox-title-inside{padding-bottom:10px;text-align:center;color:#333;position:relative}.fancybox-title-outside{padding-top:10px;color:#fff;font-weight:600}.fancybox-title-over{position:absolute;bottom:0;left:0;color:#FFF;text-align:left}.rtl .fancybox-title-over{text-align:right}#fancybox-title-over{padding:10px;background:rgba(0,0,0,.64);display:block}.fancybox-title-float{position:absolute;left:0;bottom:-20px;height:32px}#fancybox-title-float-wrap{border:0;border-collapse:collapse;width:auto}#fancybox-title-float-wrap tr,#fancybox-title-float-wrap td{border:0;white-space:nowrap}#fancybox-title-float-left{padding:0 0 0 15px;background:url('fancybox.png') -40px -90px no-repeat}#fancybox-title-float-main{color:#fff;line-height:29px;font-weight:600;font-size:14px;padding:0 0 3px 0;background:url('fancybox-x.png') 0 -40px}#fancybox-title-float-right{padding:0 0 0 15px;background:url('fancybox.png') -55px -90px no-repeat}.fancybox-hidden{display:none}
fancybox/jquery.fancybox.min.js CHANGED
@@ -1 +1 @@
1
- (function(l){var D,j,B,r,c,z,w,H,v,i,F,g=0,y={},h=[],d=0,a={},e=[],k=null,E=new Image(),u=/\.(jpg|gif|png|bmp|jpeg|webp)(.*)?$/i,p=/[^\.]\.(swf)\s*$/i,A=/[^\.]\.(svg)\s*$/i,G=/[^\.]\.(pdf)\s*$/i,m,o=1,q=0,b="",t,n,C=false,f=l.extend(l("<div/>")[0],{prop:0}),x=navigator.userAgent.match(/msie [6]/i)&&!window.XMLHttpRequest,s=document.createTouch!==undefined;_abort=function(){l.fancybox.hideActivity();E.onerror=E.onload=null;if(k){k.abort()}D.empty()},_error=function(I){if(false===y.onError(h,g,y)){l.fancybox.hideActivity();C=false;return}if(typeof I==="undefined"){I="Please try again later."}y.titleShow=false;y.width="auto";y.height="auto";D.html('<p id="fancybox-error">The requested content cannot be loaded.<br />'+I+"</p>");_process_inline()},_start=function(){var M=h[g],J,L,O,N,I,K;_abort();y=l.extend({},l.fn.fancybox.defaults,(typeof l(M).data("fancybox")=="undefined"?y:l(M).data("fancybox")));if(document.documentElement.clientWidth<y.minViewportWidth){C=false;return}K=y.onStart(h,g,y);if(K===false){C=false;return}else{if(typeof K=="object"){y=l.extend(y,K)}}O=y.title||(M.nodeName?l(M).attr("title"):M.title)||"";if(M.nodeName&&!y.orig){y.orig=l(M).find("img:first").length?l(M).find("img:first"):l(M)}if(O===""&&y.orig){O=y.orig.attr("title")||(y.titleFromAlt?y.orig.attr("alt"):"")}J=y.href||(M.nodeName?l(M).attr("href"):M.href)||null;if((/^(?:javascript)/i).test(J)||J=="#"){J=null}if(y.type){L=y.type;if(!J){J=y.content}}else{if(y.content){L="html"}else{if(l(M).hasClass("iframe")){L="iframe"}else{if(J){if(J.match(u)||l(M).hasClass("image")){L="image"}else{if(J.match(p)){L="swf"}else{if(J.match(A)){L="svg"}else{if(J.match(G)){L="pdf"}else{if(J.indexOf("#")===0){L="inline"}else{L="ajax"}}}}}}}}}if(!L){_error("No content type found.");return}if(l(M).hasClass("modal")){y.modal=true}if(L=="inline"){M=J.substr(J.indexOf("#"));L=l(M).length>0?"inline":"ajax"}y.type=L;y.href=J;y.title=O;if(y.autoDimensions){if(y.type=="html"||y.type=="inline"||y.type=="ajax"){y.width="auto";y.height="auto"}else{y.autoDimensions=false}}if(y.modal){y.overlayShow=true;y.hideOnOverlayClick=false;y.hideOnContentClick=false;y.enableEscapeButton=false;y.showCloseButton=false}y.padding=parseInt(y.padding,10);y.margin=parseInt(y.margin,10);D.css("padding",(y.padding+y.margin));l(".fancybox-inline-tmp").off("fancybox-cancel").on("fancybox-change",function(){l(this).replaceWith(z.children())});switch(L){case"html":D.html(y.content);_process_inline();break;case"inline":if(l(M).parent().is("#fancybox-content")===true){C=false;return}l('<div class="fancybox-inline-tmp" />').hide().insertBefore(l(M)).on("fancybox-cleanup",function(){l(this).replaceWith(z.children("div:first"))}).on("fancybox-cancel",function(){l(this).replaceWith(D.children("div:first"))});l(M).appendTo(D);_process_inline();break;case"image":y.keepRatio=true;C=false;l.fancybox.showActivity();E=new Image();E.onerror=function(){_error("No image found.")};E.onload=function(){C=true;E.onerror=E.onload=null;_process_image()};E.src=J;break;case"swf":y.scrolling="no";y.keepRatio=true;N='<object type="application/x-shockwave-flash" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'+y.width+'" height="'+y.height+'"><param name="movie" value="'+J+'"></param>';I="";l.each(y.swf,function(P,Q){N+='<param name="'+P+'" value="'+Q+'"></param>';I+=" "+P+'="'+Q+'"'});N+='<embed src="'+J+'" type="application/x-shockwave-flash" width="'+y.width+'" height="'+y.height+'"'+I+"></embed></object>";D.html(N);_process_inline();break;case"svg":y.scrolling="no";y.keepRatio=true;N='<object type="image/svg+xml" width="'+y.width+'" height="'+y.height+'" data="'+J+'"></object>';D.html(N);_process_inline();break;case"pdf":y.scrolling="no";N='<object type="application/pdf" width="100%" height="100%" data="'+J+'"><a href="'+J+'" style="display:block;position:absolute;top:48%;width:100%;text-align:center">'+l(M).html()+"</a></object>";D.html(N);_process_inline();break;case"ajax":C=false;l.fancybox.showActivity();y.ajax.win=y.ajax.success;k=l.ajax(l.extend({},y.ajax,{url:J,data:y.ajax.data||{},error:function(P,R,Q){if(P.status>0){_error(Q)}},success:function(Q,S,P){var R=typeof P=="object"?P:k;if(R.status==200){if(typeof y.ajax.win=="function"){K=y.ajax.win(J,Q,S,P);if(K===false){l.fancybox.hideActivity();return}else{if(typeof K=="string"||typeof K=="object"){Q=K}}}if(Q.indexOf("<!DOCTYPE")>-1||Q.indexOf("<html")>-1||Q.indexOf("<body")>-1){_error("Unexpected response.")}else{D.html(Q);_process_inline()}}}}));break;case"iframe":l.fancybox.showActivity();_show();break}},_process_inline=function(){var J=y.width,K=y.height,L=l(window).width()==0?window.innerWidth:l(window).width(),I=l(window).height()==0?window.innerHeight:l(window).height();if(J.toString().indexOf("%")>-1){J=parseInt((L-(y.margin*2))*parseFloat(J)/100,10)+"px"}else{J=J=="auto"?"auto":J+"px"}if(K.toString().indexOf("%")>-1){K=parseInt((I-(y.margin*2))*parseFloat(K)/100,10)+"px"}else{K=K=="auto"?"auto":K+"px"}D.wrapInner('<div style="width:'+J+";height:"+K+";overflow: "+(y.scrolling=="auto"?"auto":(y.scrolling=="yes"?"scroll":"hidden"))+';position:relative;"></div>');y.width=D.width();y.height=D.height();_show()},_process_image=function(){y.width=E.width;y.height=E.height;l("<img />").attr({id:"fancybox-img",src:E.src,alt:y.title}).appendTo(D);_show()},_show=function(){var J,I;if(y.type!=="iframe"){l.fancybox.hideActivity()}if(r.is(":visible")&&false===a.onCleanup(e,d,a)){l(".fancybox-inline-tmp").trigger("fancybox-cancel");C=false;return}C=true;l(z.add(B)).off();l(window).off("orientationchange.fb resize.fb scroll.fb");l(document).off("keydown.fb");if(r.is(":visible")&&a.titlePosition!=="outside"){r.css("height",r.height())}e=h;d=g;a=y;if(a.overlayShow){B.css({"background-color":a.overlayColor,opacity:a.overlayOpacity,cursor:a.hideOnOverlayClick?"pointer":"auto",height:l(document).height()});if(!B.is(":visible")){if(x){l("select:not(#fancybox-tmp select)").filter(function(){return this.style.visibility!=="hidden"}).css({visibility:"hidden"}).one("fancybox-cleanup",function(){this.style.visibility="inherit"})}B.show()}}else{B.hide()}n=_get_zoom_to();_process_title();if(r.is(":visible")){l(w.add(v).add(i)).hide();J=r.position(),t={top:J.top,left:J.left,width:r.width(),height:r.height()};I=(t.width==n.width&&t.height==n.height);z.fadeTo(a.changeFade,0.3,function(){var K=function(){z.html(D.contents()).fadeTo(a.changeFade,1,_finish)};l(".fancybox-inline-tmp").trigger("fancybox-change");z.empty().removeAttr("filter").css({"border-width":a.padding,width:n.width-a.padding*2,height:a.autoDimensions?"auto":n.height-q-a.padding*2});if(I){K()}else{f.prop=0;l(f).animate({prop:1},{duration:a.changeSpeed,easing:a.easingChange,step:_draw,complete:K})}});return}r.removeAttr("style");z.css("border-width",a.padding);if(a.transitionIn=="elastic"){t=_get_zoom_from();z.html(D.contents());r.show();if(a.opacity){n.opacity=0}f.prop=0;l(f).animate({prop:1},{duration:a.speedIn,easing:a.easingIn,step:_draw,complete:_finish});return}if(a.titlePosition=="inside"&&q>0){H.show()}z.css({width:n.width-a.padding*2,height:y.autoDimensions?"auto":n.height-q-a.padding*2}).html(D.contents());r.css(n).fadeIn(a.transitionIn=="none"?0:a.speedIn,_finish)},_format_title=function(I){if(I&&I.length){if(a.titlePosition=="float"){return'<table id="fancybox-title-float-wrap" style="border-spacing:0;border-collapse:collapse"><tr><td id="fancybox-title-float-left"></td><td id="fancybox-title-float-main">'+I+'</td><td id="fancybox-title-float-right"></td></tr></table>'}return'<div id="fancybox-title-'+a.titlePosition+'">'+I+"</div>"}return false},_process_title=function(){b=a.title||"";q=0;H.empty().removeAttr("style").removeClass();if(a.titleShow===false){H.hide();return}b=l.isFunction(a.titleFormat)?a.titleFormat(b,e,d,a):_format_title(b);if(!b||b===""){H.hide();return}H.addClass("fancybox-title-"+a.titlePosition).html(b).appendTo("body").show();switch(a.titlePosition){case"inside":H.css({width:n.width-(a.padding*2),marginLeft:a.padding,marginRight:a.padding}).appendTo(c);q=H.outerHeight(true);n.height+=q;break;case"over":H.css({marginLeft:a.padding,width:n.width-(a.padding*2),bottom:a.padding}).appendTo(c);break;case"float":H.css("left",parseInt((H.width()-n.width)/2,10)*-1).appendTo(c);break;default:H.css({width:n.width-(a.padding*2),paddingLeft:a.padding,paddingRight:a.padding}).appendTo(r);break}H.hide()},_set_navigation=function(){if(a.enableEscapeButton||a.enableKeyboardNav){l(document).on("keydown.fb",function(I){if(I.keyCode==27&&a.enableEscapeButton){I.preventDefault();l.fancybox.close()}else{if((I.keyCode==37||I.keyCode==39)&&a.enableKeyboardNav&&I.target.tagName!=="INPUT"&&I.target.tagName!=="TEXTAREA"&&I.target.tagName!=="SELECT"){I.preventDefault();l.fancybox[I.keyCode==37?"prev":"next"]()}else{if((I.keyCode==9)&&a.enableKeyboardNav&&I.target.tagName!=="INPUT"&&I.target.tagName!=="TEXTAREA"&&I.target.tagName!=="SELECT"){I.preventDefault();l.fancybox[I.shiftKey?"prev":"next"]()}}}})}if(!a.showNavArrows){v.hide();i.hide();return}if((a.cyclic&&e.length>1)||d!==0){v.show()}if((a.cyclic&&e.length>1)||d!=(e.length-1)){i.show()}},_finish=function(){if(!l.support.opacity){z.css("filter",0);r.css("filter",0)}if(a.autoDimensions){z.css("height","auto")}r.css("height","auto");if(b&&b.length){H.show()}if(a.showCloseButton){w.show()}_set_navigation();if(a.hideOnContentClick){z.on("click",l.fancybox.close)}if(a.hideOnOverlayClick){B.on("click",l.fancybox.close)}if(a.autoResize){l(window).on("resize.fb",l.fancybox.resize)}if(a.centerOnScroll&&!s){l(window).on("scroll.fb",l.fancybox.center)}if(l.fn.mousewheel){r.on("mousewheel.fb",function(I,J){if(C){I.preventDefault()}else{if(a.type=="image"&&(l(I.target).outerHeight()==0||l(I.target).prop("scrollHeight")===l(I.target).outerHeight())){I.preventDefault();l.fancybox[J>0?"prev":"next"]()}}})}if(a.type=="iframe"){l('<iframe id="fancybox-frame" name="fancybox-frame'+new Date().getTime()+'"'+(navigator.userAgent.match(/msie [6]/i)?' allowtransparency="true""':"")+' style="border:0;margin:0;overflow:'+(y.scrolling=="auto"?"auto":(y.scrolling=="yes"?"scroll":"hidden"))+'" src="'+a.href+'"'+(false===a.allowfullscreen?"":" allowfullscreen")+' allow="autoplay; encrypted-media" tabindex="999"></iframe>').appendTo(z).load(function(){l.fancybox.hideActivity()}).focus()}r.show();C=false;l.fancybox.center();a.onComplete(e,d,a);if(e.length>1){_preload_next();_preload_prev()}},_preload_next=function(){var I=typeof arguments[0]=="number"?arguments[0]:d+1;if(I>=e.length){if(a.cyclic){I=0}else{return}}if(I==d){a.enableKeyboardNav=false;r.off("mousewheel.fb");i.hide();return}if(_preload_image(I)){return}else{_preload_next(I+1)}},_preload_prev=function(){var I=typeof arguments[0]=="number"?arguments[0]:d-1;if(I<0){if(a.cyclic){I=e.length-1}else{return}}if(I==d){a.enableKeyboardNav=false;r.off("mousewheel.fb");v.hide();return}if(_preload_image(I)){return}else{_preload_prev(I-1)}},_preload_image=function(K){var J,I=e[K];if(typeof I!=="undefined"&&typeof I.href!=="undefined"&&I.href!==a.href&&(I.href.match(u)||l(I).hasClass("image"))){J=new Image();J.src=I.href;return true}else{return false}},_draw=function(J){var I={width:parseInt(t.width+(n.width-t.width)*J,10),height:parseInt(t.height+(n.height-t.height)*J,10),top:parseInt(t.top+(n.top-t.top)*J,10),left:parseInt(t.left+(n.left-t.left)*J,10)};if(typeof n.opacity!=="undefined"){I.opacity=J<0.5?0.5:J}r.css(I);z.css({width:I.width-a.padding*2,height:I.height-(q*J)-a.padding*2})},_get_viewport=function(){var I=!s&&window.innerWidth&&document.documentElement.clientWidth?Math.min(window.innerWidth,document.documentElement.clientWidth):window.innerWidth||document.documentElement.clientWidth||document.getElementsByTagName("body")[0].clientWidth,J=!s&&window.innerHeight&&document.documentElement.clientHeight?Math.min(window.innerHeight,document.documentElement.clientHeight):window.innerHeight||document.documentElement.clientHeight||document.getElementsByTagName("body")[0].clientHeight;return[I-(a.margin*2),J-(a.margin*2),l(document).scrollLeft()+a.margin,l(document).scrollTop()+a.margin]},_get_zoom_to=function(){var I=_get_viewport(),L={},J=a.padding*2,K;if(a.width.toString().indexOf("%")>-1){L.width=parseInt((I[0]*parseFloat(a.width))/100,10)}else{L.width=a.width+J}if(a.height.toString().indexOf("%")>-1){L.height=parseInt((I[1]*parseFloat(a.height))/100,10)}else{L.height=a.height+J}if(a.autoScale&&(L.width>I[0]||L.height>I[1])){if(a.keepRatio){K=a.width/a.height;if((L.width)>I[0]){L.width=I[0];L.height=parseInt(((L.width-J)/K)+J,10)}if((L.height)>I[1]){L.height=I[1];L.width=parseInt(((L.height-J)*K)+J,10)}}else{L.width=Math.min(L.width,I[0]);L.height=Math.min(L.height,I[1])}}L.top=parseInt(Math.max(I[3]-20,I[3]+((I[1]-L.height-40)*0.5)),10);L.left=parseInt(Math.max(I[2]-20,I[2]+((I[0]-L.width-40)*0.5)),10);return L},_get_obj_pos=function(I){var J=I.offset();J.top+=parseInt(I.css("paddingTop"),10)||0;J.left+=parseInt(I.css("paddingLeft"),10)||0;J.top+=parseInt(I.css("border-top-width"),10)||0;J.left+=parseInt(I.css("border-left-width"),10)||0;J.width=I.width();J.height=I.height();return J},_get_zoom_from=function(){var L=y.orig?l(y.orig):false,K={},J,I;if(L&&L.length){J=_get_obj_pos(L);K={width:J.width+(a.padding*2),height:J.height+(a.padding*2),top:J.top-a.padding-20,left:J.left-a.padding-20}}else{I=_get_viewport();K={width:a.padding*2,height:a.padding*2,top:parseInt((I[3]+I[1])*0.5,10),left:parseInt((I[2]+I[0])*0.5,10)}}return K},_animate_loading=function(){if(!j.is(":visible")){clearInterval(m);return}l("div",j).css("top",(o*-40)+"px");o=(o+1)%12};l.fn.fancybox=function(I){if(!l(this).length){return this}l(this).data("fancybox",l.extend({},I,(l.metadata?l(this).metadata():{}))).off("click.fb").on("click.fb",function(K){K.preventDefault();if(C){return}C=true;l(this).blur();h=[];g=0;var J=l(this).attr("rel")||"";if(J==""||J.replace(/alternate|external|help|license|nofollow|noreferrer|noopener|\s+/gi,"")==""){h.push(this)}else{h=l('a[rel="'+J+'"], area[rel="'+J+'"]');g=h.index(this)}_start();return});return this};l.fancybox=function(L){var K;if(C){return}C=true;K=typeof arguments[1]!=="undefined"?arguments[1]:{};h=[];g=parseInt(K.index,10)||0;if(l.isArray(L)){for(var J=0,I=L.length;J<I;J++){if(typeof L[J]=="object"){l(L[J]).data("fancybox",l.extend({},K,L[J]))}else{L[J]=l({}).data("fancybox",l.extend({content:L[J]},K))}}h=jQuery.merge(h,L)}else{if(typeof L=="object"){l(L).data("fancybox",l.extend({},K,L))}else{L=l({}).data("fancybox",l.extend({content:L},K))}h.push(L)}if(g>h.length||g<0){g=0}_start()};l.fancybox.showActivity=function(){clearInterval(m);j.show();m=setInterval(_animate_loading,66)};l.fancybox.hideActivity=function(){j.hide()};l.fancybox.next=function(){var I,J=typeof arguments[0]=="number"?arguments[0]:d+1;if(J>=e.length){if(a.cyclic){J=0}else{return}}I=e[J];if(J!=d&&typeof I!=="undefined"&&typeof I.href!=="undefined"&&I.href===a.href){l.fancybox.next(J+1)}else{l.fancybox.pos(J)}return};l.fancybox.prev=function(){var I,J=typeof arguments[0]=="number"?arguments[0]:d-1;if(J<0){if(a.cyclic){J=e.length-1}else{return}}I=e[J];if(J!=d&&typeof I!=="undefined"&&typeof I.href!=="undefined"&&I.href===a.href){l.fancybox.prev(J-1)}else{l.fancybox.pos(J)}return};l.fancybox.pos=function(I){if(C){return}I=parseInt(I);h=e;if(I>-1&&I<e.length){g=I;_start()}return};l.fancybox.cancel=function(){if(C){return}C=true;l(".fancybox-inline-tmp").trigger("fancybox-cancel");_abort();y.onCancel(h,g,y);C=false};l.fancybox.close=function(){if(C||r.is(":hidden")){return}C=true;if(a&&false===a.onCleanup(e,d,a)){C=false;return}_abort();l(w.add(v).add(i)).hide();l(z.add(B)).off();l(window).off("orientationchange.fb resize.fb scroll.fb mousewheel.fb");l(document).off("keydown.fb");z.find("iframe#fancybox-frame").attr("src",x&&/^https/i.test(window.location.href||"")?"javascript:void(false)":"about:blank");if(a.titlePosition!=="inside"){H.empty()}r.stop();function I(){B.fadeOut("fast");H.empty().hide();r.hide();l(".fancybox-inline-tmp").trigger("fancybox-cleanup");z.empty();a.onClosed(e,d,a);e=y=[];d=g=0;a=y={};C=false}if(a.transitionOut=="elastic"){t=_get_zoom_from();var J=r.position();n={top:J.top,left:J.left,width:r.width(),height:r.height()};if(a.opacity){n.opacity=1}H.empty().hide();f.prop=1;l(f).animate({prop:0},{duration:a.speedOut,easing:a.easingOut,step:_draw,complete:I})}else{r.fadeOut(a.transitionOut=="none"?0:a.speedOut,I)}};l.fancybox.resize=function(){var I;clearTimeout(F);F=setTimeout(function(){var J=function(){if(y.autoDimensions){z.css("height","auto")}r.css("height","auto");if(b&&b.length){H.show()}C=false;l.fancybox.center(true)};if(B.is(":visible")){B.css("height",l(document).height())}I=r.position(),t={top:I.top,left:I.left,width:r.width(),height:r.height()};n=_get_zoom_to();C=true;_process_title();f.prop=0;l(f).animate({prop:1},{duration:a.changeSpeed,easing:a.easingChange,step:_draw,complete:J})},500)};l.fancybox.center=function(){var I,J;if(C){return}J=arguments[0]===true?1:0;I=_get_viewport();if(!J&&(r.width()>I[0]||r.height()>I[1])){return}r.stop().animate({top:parseInt(Math.max(I[3]-20,I[3]+((I[1]-z.height()-40)*0.5)-a.padding)),left:parseInt(Math.max(I[2]-20,I[2]+((I[0]-z.width()-40)*0.5)-a.padding))},typeof arguments[0]=="number"?arguments[0]:300)};l.fancybox.init=function(){if(l("#fancybox-wrap").length){return}l("body").append(D=l('<div id="fancybox-tmp"></div>'),j=l('<div id="fancybox-loading"><div></div></div>'),B=l('<div id="fancybox-overlay"></div>'),r=l('<div id="fancybox-wrap"></div>'));c=l('<div id="fancybox-outer"></div>').append('<div class="fancybox-bg" id="fancybox-bg-n"></div><div class="fancybox-bg" id="fancybox-bg-ne"></div><div class="fancybox-bg" id="fancybox-bg-e"></div><div class="fancybox-bg" id="fancybox-bg-se"></div><div class="fancybox-bg" id="fancybox-bg-s"></div><div class="fancybox-bg" id="fancybox-bg-sw"></div><div class="fancybox-bg" id="fancybox-bg-w"></div><div class="fancybox-bg" id="fancybox-bg-nw"></div>').appendTo(r);c.append(z=l('<div id="fancybox-content"></div>'),w=l('<a id="fancybox-close"></a>'),H=l('<div id="fancybox-title"></div>'),v=l('<a href="javascript:;" id="fancybox-left"><span class="fancy-ico" id="fancybox-left-ico"></span></a>'),i=l('<a href="javascript:;" id="fancybox-right"><span class="fancy-ico" id="fancybox-right-ico"></span></a>'));w.click(l.fancybox.close);j.click(l.fancybox.cancel);v.click(function(I){I.preventDefault();l.fancybox.prev()});i.click(function(I){I.preventDefault();l.fancybox.next()});if(!l.support.opacity){r.addClass("fancybox-ie")}if(x){j.addClass("fancybox-ie6");r.addClass("fancybox-ie6");l('<iframe id="fancybox-hide-sel-frame" src="'+(/^https/i.test(window.location.href||"")?"javascript:void(false)":"about:blank")+'" style="overflow:hidden;border:0" tabindex="-1"></iframe>').prependTo(c)}};l.fn.fancybox.defaults={padding:10,margin:40,opacity:false,modal:false,cyclic:false,allowfullscreen:false,scrolling:"auto",width:560,height:340,autoScale:true,autoDimensions:true,centerOnScroll:false,autoResize:true,keepRatio:false,minViewportWidth:0,ajax:{},swf:{wmode:"opaque"},svg:{wmode:"opaque"},hideOnOverlayClick:true,hideOnContentClick:false,overlayShow:true,overlayOpacity:0.7,overlayColor:"#777",titleShow:true,titlePosition:"float",titleFormat:null,titleFromAlt:true,transitionIn:"fade",transitionOut:"fade",speedIn:300,speedOut:300,changeSpeed:300,changeFade:"fast",easingIn:"swing",easingOut:"swing",showCloseButton:true,showNavArrows:true,enableEscapeButton:true,enableKeyboardNav:true,onStart:function(){},onCancel:function(){},onComplete:function(){},onCleanup:function(){},onClosed:function(){},onError:function(){}};l(document).ready(function(){l.fancybox.init()})})(jQuery);
1
+ (function(l){var D,j,B,r,c,z,w,H,v,i,F,g=0,y={},h=[],d=0,a={},e=[],k=null,E=new Image(),u=/\.(jpg|gif|png|bmp|jpeg|webp)(.*)?$/i,p=/[^\.]\.(swf)\s*$/i,A=/[^\.]\.(svg)\s*$/i,G=/[^\.]\.(pdf)\s*$/i,m,o=1,q=0,b="",t,n,C=false,f=l.extend(l("<div/>")[0],{prop:0}),x=navigator.userAgent.match(/msie [6]/i)&&!window.XMLHttpRequest,s=document.createTouch!==undefined;_abort=function(){l.fancybox.hideActivity();E.onerror=E.onload=null;if(k){k.abort()}D.empty()},_error=function(I){if(false===y.onError(h,g,y)){l.fancybox.hideActivity();C=false;return}if(typeof I==="undefined"){I="Please try again later."}y.titleShow=false;y.width="auto";y.height="auto";D.html('<p id="fancybox-error">The requested content cannot be loaded.<br />'+I+"</p>");_process_inline()},_start=function(){var M=h[g],J,L,O,N,I,K;_abort();y=l.extend({},l.fn.fancybox.defaults,(typeof l(M).data("fancybox")=="undefined"?y:l(M).data("fancybox")));if(document.documentElement.clientWidth<y.minViewportWidth){C=false;return}if("object"===typeof arguments[0]&&"click"===arguments[0].type){arguments[0].preventDefault()}K=y.onStart(h,g,y);if(K===false){C=false;return}else{if(typeof K=="object"){y=l.extend(y,K)}}O=y.title||(M.nodeName?l(M).attr("title"):M.title)||"";if(M.nodeName&&!y.orig){y.orig=l(M).find("img:first").length?l(M).find("img:first"):l(M)}if(O===""&&y.orig){O=y.orig.attr("title")||(y.titleFromAlt?y.orig.attr("alt"):"")}J=y.href||(M.nodeName?l(M).attr("href"):M.href)||null;if((/^(?:javascript)/i).test(J)||J=="#"){J=null}if(y.type){L=y.type;if(!J){J=y.content}}else{if(y.content){L="html"}else{if(l(M).hasClass("iframe")){L="iframe"}else{if(J){if(J.match(u)||l(M).hasClass("image")){L="image"}else{if(J.match(p)){L="swf"}else{if(J.match(A)){L="svg"}else{if(J.match(G)){L="pdf"}else{if(J.indexOf("#")===0){L="inline"}else{L="ajax"}}}}}}}}}if(!L){_error("No content type found.");return}if(l(M).hasClass("modal")){y.modal=true}if(L=="inline"){M=J.substr(J.indexOf("#"));L=l(M).length>0?"inline":"ajax"}y.type=L;y.href=J;y.title=O;if(y.autoDimensions){if(y.type=="html"||y.type=="inline"||y.type=="ajax"){y.width="auto";y.height="auto"}else{y.autoDimensions=false}}if(y.modal){y.overlayShow=true;y.hideOnOverlayClick=false;y.hideOnContentClick=false;y.enableEscapeButton=false;y.showCloseButton=false}y.padding=parseInt(y.padding,10);y.margin=parseInt(y.margin,10);D.css("padding",(y.padding+y.margin));l(".fancybox-inline-tmp").off("fancybox-cancel").on("fancybox-change",function(){l(this).replaceWith(z.children())});switch(L){case"html":D.html(y.content);_process_inline();break;case"inline":if(l(M).parent().is("#fancybox-content")===true){C=false;return}l('<div class="fancybox-inline-tmp" />').hide().insertBefore(l(M)).on("fancybox-cleanup",function(){l(this).replaceWith(z.children("div:first"))}).on("fancybox-cancel",function(){l(this).replaceWith(D.children("div:first"))});l(M).appendTo(D);_process_inline();break;case"image":y.keepRatio=true;C=false;l.fancybox.showActivity();E=new Image();E.onerror=function(){_error("No image found.")};E.onload=function(){C=true;E.onerror=E.onload=null;_process_image()};E.src=J;break;case"swf":y.scrolling="no";y.keepRatio=true;N='<object type="application/x-shockwave-flash" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'+y.width+'" height="'+y.height+'"><param name="movie" value="'+J+'"></param>';I="";l.each(y.swf,function(P,Q){N+='<param name="'+P+'" value="'+Q+'"></param>';I+=" "+P+'="'+Q+'"'});N+='<embed src="'+J+'" type="application/x-shockwave-flash" width="'+y.width+'" height="'+y.height+'"'+I+"></embed></object>";D.html(N);_process_inline();break;case"svg":y.scrolling="no";y.keepRatio=true;N='<object type="image/svg+xml" width="'+y.width+'" height="'+y.height+'" data="'+J+'"></object>';D.html(N);_process_inline();break;case"pdf":y.scrolling="no";N='<object type="application/pdf" width="100%" height="100%" data="'+J+'"><a href="'+J+'" style="display:block;position:absolute;top:48%;width:100%;text-align:center">'+l(M).html()+"</a></object>";D.html(N);_process_inline();break;case"ajax":C=false;l.fancybox.showActivity();y.ajax.win=y.ajax.success;k=l.ajax(l.extend({},y.ajax,{url:J,data:y.ajax.data||{},error:function(P,R,Q){if(P.status>0){_error(Q)}},success:function(Q,S,P){var R=typeof P=="object"?P:k;if(R.status==200){if(typeof y.ajax.win=="function"){K=y.ajax.win(J,Q,S,P);if(K===false){l.fancybox.hideActivity();return}else{if(typeof K=="string"||typeof K=="object"){Q=K}}}if(Q.indexOf("<!DOCTYPE")>-1||Q.indexOf("<html")>-1||Q.indexOf("<body")>-1){_error("Unexpected response.")}else{D.html(Q);_process_inline()}}}}));break;case"iframe":l.fancybox.showActivity();_show();break}},_process_inline=function(){var J=y.width,K=y.height,L=l(window).width()==0?window.innerWidth:l(window).width(),I=l(window).height()==0?window.innerHeight:l(window).height();if(J.toString().indexOf("%")>-1){J=parseInt((L-(y.margin*2))*parseFloat(J)/100,10)+"px"}else{J=J=="auto"?"auto":J+"px"}if(K.toString().indexOf("%")>-1){K=parseInt((I-(y.margin*2))*parseFloat(K)/100,10)+"px"}else{K=K=="auto"?"auto":K+"px"}D.wrapInner('<div style="width:'+J+";height:"+K+";overflow: "+(y.scrolling=="auto"?"auto":(y.scrolling=="yes"?"scroll":"hidden"))+';position:relative;"></div>');y.width=D.width();y.height=D.height();_show()},_process_image=function(){y.width=E.width;y.height=E.height;l("<img />").attr({id:"fancybox-img",src:E.src,alt:y.title}).appendTo(D);_show()},_show=function(){var J,I;if(y.type!=="iframe"){l.fancybox.hideActivity()}if(r.is(":visible")&&false===a.onCleanup(e,d,a)){l(".fancybox-inline-tmp").trigger("fancybox-cancel");C=false;return}C=true;l(z.add(B)).off();l(window).off("orientationchange.fb resize.fb scroll.fb");l(document).off("keydown.fb");if(r.is(":visible")&&a.titlePosition!=="outside"){r.css("height",r.height())}e=h;d=g;a=y;if(a.overlayShow){B.css({"background-color":a.overlayColor,opacity:a.overlayOpacity,cursor:a.hideOnOverlayClick?"pointer":"auto",height:l(document).height()});if(!B.is(":visible")){if(x){l("select:not(#fancybox-tmp select)").filter(function(){return this.style.visibility!=="hidden"}).css({visibility:"hidden"}).one("fancybox-cleanup",function(){this.style.visibility="inherit"})}B.show()}}else{B.hide()}n=_get_zoom_to();_process_title();if(r.is(":visible")){l(w.add(v).add(i)).hide();J=r.position(),t={top:J.top,left:J.left,width:r.width(),height:r.height()};I=(t.width==n.width&&t.height==n.height);z.fadeTo(a.changeFade,0.3,function(){var K=function(){z.html(D.contents()).fadeTo(a.changeFade,1,_finish)};l(".fancybox-inline-tmp").trigger("fancybox-change");z.empty().removeAttr("filter").css({"border-width":a.padding,width:n.width-a.padding*2,height:a.autoDimensions?"auto":n.height-q-a.padding*2});if(I){K()}else{f.prop=0;l(f).animate({prop:1},{duration:a.changeSpeed,easing:a.easingChange,step:_draw,complete:K})}});return}r.removeAttr("style");z.css("border-width",a.padding);if(a.transitionIn=="elastic"){t=_get_zoom_from();z.html(D.contents());r.show();if(a.opacity){n.opacity=0}f.prop=0;l(f).animate({prop:1},{duration:a.speedIn,easing:a.easingIn,step:_draw,complete:_finish});return}if(a.titlePosition=="inside"&&q>0){H.show()}z.css({width:n.width-a.padding*2,height:a.autoDimensions?"auto":n.height-q-a.padding*2}).html(D.contents());r.css(n).fadeIn(a.transitionIn=="none"?0:a.speedIn,_finish)},_format_title=function(I){if(I&&I.length){if(a.titlePosition=="float"){return'<table id="fancybox-title-float-wrap" style="border-spacing:0;border-collapse:collapse"><tr><td id="fancybox-title-float-left"></td><td id="fancybox-title-float-main">'+I+'</td><td id="fancybox-title-float-right"></td></tr></table>'}return'<div id="fancybox-title-'+a.titlePosition+'">'+I+"</div>"}return false},_process_title=function(){b=a.title||"";q=0;H.empty().removeAttr("style").removeClass();if(a.titleShow===false){H.hide();return}b=l.isFunction(a.titleFormat)?a.titleFormat(b,e,d,a):_format_title(b);if(!b||b===""){H.hide();return}H.addClass("fancybox-title-"+a.titlePosition).html(b).appendTo("body").show();switch(a.titlePosition){case"inside":H.css({width:n.width-(a.padding*2),marginLeft:a.padding,marginRight:a.padding}).appendTo(c);q=H.outerHeight(true);n.height+=q;break;case"over":H.css({marginLeft:a.padding,width:n.width-(a.padding*2),bottom:a.padding}).appendTo(c);break;case"float":H.css("left",parseInt((H.width()-n.width)/2,10)*-1).appendTo(c);break;default:H.css({width:n.width-(a.padding*2),paddingLeft:a.padding,paddingRight:a.padding}).appendTo(r);break}H.hide()},_set_navigation=function(){if(a.enableEscapeButton||a.enableKeyboardNav){l(document).on("keydown.fb",function(I){if(I.keyCode==27&&a.enableEscapeButton){I.preventDefault();l.fancybox.close()}else{if((I.keyCode==37||I.keyCode==39)&&a.enableKeyboardNav&&I.target.tagName!=="INPUT"&&I.target.tagName!=="TEXTAREA"&&I.target.tagName!=="SELECT"){I.preventDefault();l.fancybox[I.keyCode==37?"prev":"next"]()}else{if((I.keyCode==9)&&a.enableKeyboardNav&&I.target.tagName!=="INPUT"&&I.target.tagName!=="TEXTAREA"&&I.target.tagName!=="SELECT"){I.preventDefault();l.fancybox[I.shiftKey?"prev":"next"]()}}}})}if(!a.showNavArrows){v.hide();i.hide();return}if((a.cyclic&&e.length>1)||d!==0){v.show()}if((a.cyclic&&e.length>1)||d!=(e.length-1)){i.show()}},_finish=function(){if(!l.support.opacity){z.css("filter",0);r.css("filter",0)}if(a.autoDimensions){z.css("height","auto")}r.css("height","auto");if(b&&b.length){H.show()}if(a.showCloseButton){w.show()}_set_navigation();if(a.hideOnContentClick){z.on("click",l.fancybox.close)}if(a.hideOnOverlayClick){B.on("click",l.fancybox.close)}if(a.autoResize){l(window).on("resize.fb",l.fancybox.resize)}if(a.centerOnScroll&&!s){l(window).on("scroll.fb",l.fancybox.center)}if(l.fn.mousewheel){r.on("mousewheel.fb",function(I,J){if(C){I.preventDefault()}else{if(a.type=="image"&&(l(I.target).outerHeight()==0||l(I.target).prop("scrollHeight")===l(I.target).outerHeight())){I.preventDefault();l.fancybox[J>0?"prev":"next"]()}}})}if(a.type=="iframe"){l('<iframe id="fancybox-frame" name="fancybox-frame'+new Date().getTime()+'"'+(navigator.userAgent.match(/msie [6]/i)?' allowtransparency="true""':"")+' style="border:0;margin:0;overflow:'+(a.scrolling=="auto"?"auto":(a.scrolling=="yes"?"scroll":"hidden"))+'" src="'+a.href+'"'+(false===a.allowfullscreen?"":" allowfullscreen")+' allow="autoplay; encrypted-media" tabindex="999"></iframe>').appendTo(z).load(function(){l.fancybox.hideActivity()}).focus()}r.show();C=false;l.fancybox.center();a.onComplete(e,d,a);if(e.length>1){_preload_next();_preload_prev()}},_preload_next=function(){var I=typeof arguments[0]=="number"?arguments[0]:d+1;if(I>=e.length){if(a.cyclic){I=0}else{return}}if(I==d){a.enableKeyboardNav=false;r.off("mousewheel.fb");i.hide();return}if(_preload_image(I)){return}else{_preload_next(I+1)}},_preload_prev=function(){var I=typeof arguments[0]=="number"?arguments[0]:d-1;if(I<0){if(a.cyclic){I=e.length-1}else{return}}if(I==d){a.enableKeyboardNav=false;r.off("mousewheel.fb");v.hide();return}if(_preload_image(I)){return}else{_preload_prev(I-1)}},_preload_image=function(K){var J,I=e[K];if(typeof I!=="undefined"&&typeof I.href!=="undefined"&&I.href!==a.href&&(I.href.match(u)||l(I).hasClass("image"))){J=new Image();J.src=I.href;return true}else{return false}},_draw=function(J){var I={width:parseInt(t.width+(n.width-t.width)*J,10),height:parseInt(t.height+(n.height-t.height)*J,10),top:parseInt(t.top+(n.top-t.top)*J,10),left:parseInt(t.left+(n.left-t.left)*J,10)};if(typeof n.opacity!=="undefined"){I.opacity=J<0.5?0.5:J}r.css(I);z.css({width:I.width-a.padding*2,height:I.height-(q*J)-a.padding*2})},_get_viewport=function(){var I=!s&&window.innerWidth&&document.documentElement.clientWidth?Math.min(window.innerWidth,document.documentElement.clientWidth):window.innerWidth||document.documentElement.clientWidth||document.getElementsByTagName("body")[0].clientWidth,J=!s&&window.innerHeight&&document.documentElement.clientHeight?Math.min(window.innerHeight,document.documentElement.clientHeight):window.innerHeight||document.documentElement.clientHeight||document.getElementsByTagName("body")[0].clientHeight,K;K=arguments[0]===true?0:a.margin;return[I-(K*2),J-(K*2),l(document).scrollLeft()+K,l(document).scrollTop()+K]},_get_zoom_to=function(){var I=_get_viewport(),L={},J=a.padding*2,K;if(a.width.toString().indexOf("%")>-1){L.width=parseInt((I[0]*parseFloat(a.width))/100,10)}else{L.width=a.width+J}if(a.height.toString().indexOf("%")>-1){L.height=parseInt((I[1]*parseFloat(a.height))/100,10)}else{L.height=a.height+J}if(a.autoScale&&(L.width>I[0]||L.height>I[1])){if(a.keepRatio){K=a.width/a.height;if((L.width)>I[0]){L.width=I[0];L.height=parseInt(((L.width-J)/K)+J,10)}if((L.height)>I[1]){L.height=I[1];L.width=parseInt(((L.height-J)*K)+J,10)}}else{L.width=Math.min(L.width,I[0]);L.height=Math.min(L.height,I[1])}}L.top=parseInt(Math.max(I[3]-20,I[3]+((I[1]-L.height-40)*0.5)),10);L.left=parseInt(Math.max(I[2]-20,I[2]+((I[0]-L.width-40)*0.5)),10);return L},_get_obj_pos=function(I){var J=I.offset();J.top+=parseInt(I.css("paddingTop"),10)||0;J.left+=parseInt(I.css("paddingLeft"),10)||0;J.top+=parseInt(I.css("border-top-width"),10)||0;J.left+=parseInt(I.css("border-left-width"),10)||0;J.width=I.width();J.height=I.height();return J},_get_zoom_from=function(){var L=y.orig?l(y.orig):false,K={},J,I;if(L&&L.length){J=_get_obj_pos(L);K={width:J.width+(a.padding*2),height:J.height+(a.padding*2),top:J.top-a.padding-20,left:J.left-a.padding-20}}else{I=_get_viewport();K={width:a.padding*2,height:a.padding*2,top:parseInt((I[3]+I[1])*0.5,10),left:parseInt((I[2]+I[0])*0.5,10)}}return K},_animate_loading=function(){if(!j.is(":visible")){clearInterval(m);return}l("div",j).css("top",(o*-40)+"px");o=(o+1)%12};l.fn.fancybox=function(I){if(!l(this).length){return this}l(this).data("fancybox",l.extend({},I,(l.metadata?l(this).metadata():{}))).off("click.fb").on("click.fb",function(K){if(C){return}C=true;l(this).blur();h=[];g=0;var J=l(this).attr("rel")||"";if(J==""||J.replace(/alternate|external|help|license|nofollow|noreferrer|noopener|\s+/gi,"")==""){h.push(this)}else{h=l('a[rel="'+J+'"], area[rel="'+J+'"]');g=h.index(this)}_start(K);return});return this};l.fancybox=function(L){var K;if(C){return}C=true;K=typeof arguments[1]!=="undefined"?arguments[1]:{};h=[];g=parseInt(K.index,10)||0;if(l.isArray(L)){for(var J=0,I=L.length;J<I;J++){if(typeof L[J]=="object"){l(L[J]).data("fancybox",l.extend({},K,L[J]))}else{L[J]=l({}).data("fancybox",l.extend({content:L[J]},K))}}h=jQuery.merge(h,L)}else{if(typeof L=="object"){l(L).data("fancybox",l.extend({},K,L))}else{L=l({}).data("fancybox",l.extend({content:L},K))}h.push(L)}if(g>h.length||g<0){g=0}_start()};l.fancybox.showActivity=function(){clearInterval(m);j.show();m=setInterval(_animate_loading,66)};l.fancybox.hideActivity=function(){j.hide()};l.fancybox.next=function(){var I,J=typeof arguments[0]=="number"?arguments[0]:d+1;if(J>=e.length){if(a.cyclic){J=0}else{return}}I=e[J];if(J!=d&&typeof I!=="undefined"&&typeof I.href!=="undefined"&&I.href===a.href){l.fancybox.next(J+1)}else{l.fancybox.pos(J)}return};l.fancybox.prev=function(){var I,J=typeof arguments[0]=="number"?arguments[0]:d-1;if(J<0){if(a.cyclic){J=e.length-1}else{return}}I=e[J];if(J!=d&&typeof I!=="undefined"&&typeof I.href!=="undefined"&&I.href===a.href){l.fancybox.prev(J-1)}else{l.fancybox.pos(J)}return};l.fancybox.pos=function(I){if(C){return}I=parseInt(I);h=e;if(I>-1&&I<e.length){g=I;_start()}return};l.fancybox.cancel=function(){if(C){return}C=true;l(".fancybox-inline-tmp").trigger("fancybox-cancel");_abort();y.onCancel(h,g,y);C=false};l.fancybox.close=function(){if(C||r.is(":hidden")){return}C=true;if(a&&false===a.onCleanup(e,d,a)){C=false;return}_abort();l(w.add(v).add(i)).hide();l(z.add(B)).off();l(window).off("orientationchange.fb resize.fb scroll.fb mousewheel.fb");l(document).off("keydown.fb");z.find("iframe#fancybox-frame").attr("src",x&&/^https/i.test(window.location.href||"")?"javascript:void(false)":"about:blank");if(a.titlePosition!=="inside"){H.empty()}r.stop();function I(){B.fadeOut("fast");H.empty().hide();r.hide();l(".fancybox-inline-tmp").trigger("fancybox-cleanup");z.empty();a.onClosed(e,d,a);e=y=[];d=g=0;a=y={};C=false}if(a.transitionOut=="elastic"){t=_get_zoom_from();var J=r.position();n={top:J.top,left:J.left,width:r.width(),height:r.height()};if(a.opacity){n.opacity=1}H.empty().hide();f.prop=1;l(f).animate({prop:0},{duration:a.speedOut,easing:a.easingOut,step:_draw,complete:I})}else{r.fadeOut(a.transitionOut=="none"?0:a.speedOut,I)}};l.fancybox.resize=function(){var I;clearTimeout(F);F=setTimeout(function(){var J=function(){if(y.autoDimensions){z.css("height","auto")}r.css("height","auto");if(b&&b.length){H.show()}C=false;l.fancybox.center(true)};if(B.is(":visible")){B.css("height",l(document).height())}I=r.position(),t={top:I.top,left:I.left,width:r.width(),height:r.height()};n=_get_zoom_to();C=true;_process_title();f.prop=0;l(f).animate({prop:1},{duration:a.changeSpeed,easing:a.easingChange,step:_draw,complete:J})},500)};l.fancybox.center=function(){var I,J;if(C){return}J=arguments[0]===true?1:0;I=_get_viewport(true);if(!J&&((r.width()+40)>I[0]||(r.height()+40)>I[1])){return}r.stop().animate({top:parseInt(Math.max(I[3]-20,I[3]+((I[1]-z.height()-40)*0.5)-a.padding)),left:parseInt(Math.max(I[2]-20,I[2]+((I[0]-z.width()-40)*0.5)-a.padding))},typeof arguments[0]=="number"?arguments[0]:300)};l.fancybox.init=function(){if(l("#fancybox-wrap").length){return}l("body").append(D=l('<div id="fancybox-tmp"></div>'),j=l('<div id="fancybox-loading"><div></div></div>'),B=l('<div id="fancybox-overlay"></div>'),r=l('<div id="fancybox-wrap"></div>'));c=l('<div id="fancybox-outer"></div>').append('<div class="fancybox-bg" id="fancybox-bg-n"></div><div class="fancybox-bg" id="fancybox-bg-ne"></div><div class="fancybox-bg" id="fancybox-bg-e"></div><div class="fancybox-bg" id="fancybox-bg-se"></div><div class="fancybox-bg" id="fancybox-bg-s"></div><div class="fancybox-bg" id="fancybox-bg-sw"></div><div class="fancybox-bg" id="fancybox-bg-w"></div><div class="fancybox-bg" id="fancybox-bg-nw"></div>').appendTo(r);c.append(z=l('<div id="fancybox-content"></div>'),w=l('<a id="fancybox-close"></a>'),H=l('<div id="fancybox-title"></div>'),v=l('<a href="javascript:;" id="fancybox-left"><span class="fancy-ico" id="fancybox-left-ico"></span></a>'),i=l('<a href="javascript:;" id="fancybox-right"><span class="fancy-ico" id="fancybox-right-ico"></span></a>'));w.click(l.fancybox.close);j.click(l.fancybox.cancel);v.click(function(I){I.preventDefault();l.fancybox.prev()});i.click(function(I){I.preventDefault();l.fancybox.next()});if(!l.support.opacity){r.addClass("fancybox-ie")}if(x){j.addClass("fancybox-ie6");r.addClass("fancybox-ie6");l('<iframe id="fancybox-hide-sel-frame" src="'+(/^https/i.test(window.location.href||"")?"javascript:void(false)":"about:blank")+'" style="overflow:hidden;border:0" tabindex="-1"></iframe>').prependTo(c)}};l.fn.fancybox.defaults={padding:10,margin:40,opacity:false,modal:false,cyclic:false,allowfullscreen:false,scrolling:"auto",width:560,height:340,autoScale:true,autoDimensions:true,centerOnScroll:false,autoResize:true,keepRatio:false,minViewportWidth:0,ajax:{},swf:{wmode:"opaque"},svg:{wmode:"opaque"},hideOnOverlayClick:true,hideOnContentClick:false,overlayShow:true,overlayOpacity:0.7,overlayColor:"#777",titleShow:true,titlePosition:"float",titleFormat:null,titleFromAlt:true,transitionIn:"fade",transitionOut:"fade",speedIn:300,speedOut:300,changeSpeed:300,changeFade:"fast",easingIn:"swing",easingOut:"swing",showCloseButton:true,showNavArrows:true,enableEscapeButton:true,enableKeyboardNav:true,onStart:function(){},onCancel:function(){},onComplete:function(){},onCleanup:function(){},onClosed:function(){},onError:function(){}};l(document).ready(function(){l.fancybox.init()})})(jQuery);
inc/class-easyfancybox-admin.php CHANGED
@@ -29,27 +29,29 @@ class easyFancyBox_Admin extends easyFancyBox {
29
 
30
  switch($value['input']) {
31
  case 'deep':
32
- // go deeper by looping back on itself
33
- self::register_settings($value['options']);
34
- break;
 
35
  case 'multiple':
36
- add_settings_field( 'fancybox_'.$key, '<a name="'.$value['title'].'"></a>'.$value['title'], array(__CLASS__, 'settings_fields'), 'media', 'fancybox_section', $value);
37
- foreach ( $value['options'] as $_value ) {
38
- if ( !isset($_value['sanitize_callback']) )
39
- $sanitize_callback = '';
40
- else
41
- $sanitize_callback = array(__CLASS__, $_value['sanitize_callback']);
42
- if ( isset($_value['id']) )
43
- register_setting( 'media', $_value['id'], $sanitize_callback );
44
- }
45
- break;
 
46
  default:
47
- if ( !isset($value['sanitize_callback']) )
48
- $sanitize_callback = '';
49
- else
50
- $sanitize_callback = array(__CLASS__, $value['sanitize_callback']);
51
- if ( isset($value['id']) )
52
- register_setting( 'media', 'fancybox_'.$key, $sanitize_callback );
53
  }
54
  }
55
  }
29
 
30
  switch($value['input']) {
31
  case 'deep':
32
+ // go deeper by looping back on itself
33
+ self::register_settings($value['options']);
34
+ break;
35
+
36
  case 'multiple':
37
+ add_settings_field( 'fancybox_'.$key, '<a name="'.$value['title'].'"></a>'.$value['title'], array(__CLASS__, 'settings_fields'), 'media', 'fancybox_section', $value);
38
+ foreach ( $value['options'] as $_value ) {
39
+ if ( !isset($_value['sanitize_callback']) )
40
+ $sanitize_callback = '';
41
+ else
42
+ $sanitize_callback = array(__CLASS__, $_value['sanitize_callback']);
43
+ if ( isset($_value['id']) )
44
+ register_setting( 'media', $_value['id'], $sanitize_callback );
45
+ }
46
+ break;
47
+
48
  default:
49
+ if ( !isset($value['sanitize_callback']) )
50
+ $sanitize_callback = '';
51
+ else
52
+ $sanitize_callback = array(__CLASS__, $value['sanitize_callback']);
53
+ if ( isset($value['id']) )
54
+ register_setting( 'media', 'fancybox_'.$key, $sanitize_callback );
55
  }
56
  }
57
  }
inc/class-easyfancybox-options.php DELETED
@@ -1,1603 +0,0 @@
1
- <?php
2
- /**
3
- * Easy FancyBox Options Class
4
- */
5
-
6
- class easyFancyBox_Options extends easyFancyBox {
7
-
8
- public static function load_defaults() {
9
-
10
- $url = "https://premium.status301.net/downloads/easy-fancybox-pro/";
11
-
12
- if ( empty(parent::$options) )
13
- parent::$options = array (
14
-
15
- 'Global' => array(
16
- 'title' => __('Global settings','easy-fancybox'),
17
- 'input' => 'deep',
18
- 'hide' => true,
19
- 'options' => array(
20
- 'Enable' => array (
21
- 'title' => __('Media','easy-fancybox'),
22
- 'input' => 'multiple',
23
- 'hide' => true,
24
- 'options' => array(
25
- 'p1' => array (
26
- 'hide' => true,
27
- 'description' => __('Enable FancyBox for','easy-fancybox') . '<br />'
28
- ),
29
- 'IMG' => array (
30
- 'id' => 'fancybox_enableImg',
31
- 'input' => 'checkbox',
32
- 'hide' => true,
33
- 'default' => ( function_exists('is_plugin_active_for_network') && is_plugin_active_for_network( parent::$plugin_basename ) ) ? '' : '1',
34
- 'description' => '<strong>' . __('Images','easy-fancybox') . '</strong>'
35
- ),
36
- 'Inline' => array (
37
- 'id' => 'fancybox_enableInline',
38
- 'input' => 'checkbox',
39
- 'hide' => true,
40
- 'default' => '',
41
- 'description' => '<strong>' . __('Inline content','easy-fancybox') . '</strong>'
42
- ),
43
- 'PDF' => array (
44
- 'id' => 'fancybox_enablePDF',
45
- 'input' => 'checkbox',
46
- 'hide' => true,
47
- 'default' => '',
48
- 'description' => '<strong>' . __('PDF','easy-fancybox') . '</strong>'
49
- ),
50
- 'SWF' => array (
51
- 'id' => 'fancybox_enableSWF',
52
- 'input' => 'checkbox',
53
- 'hide' => true,
54
- 'default' => '',
55
- 'description' => '<strong>' . __('SWF','easy-fancybox') . '</strong>'
56
- ),
57
- 'SVG' => array (
58
- 'id' => 'fancybox_enableSVG',
59
- 'input' => 'checkbox',
60
- 'hide' => true,
61
- 'default' => '',
62
- 'description' => '<strong>' . __('SVG','easy-fancybox') . '</strong>'
63
- ),
64
- 'YouTube' => array (
65
- 'id' => 'fancybox_enableYoutube',
66
- 'input' => 'checkbox',
67
- 'hide' => true,
68
- 'default' => '',
69
- 'description' => '<strong>' . __('YouTube','easy-fancybox') . '</strong>'
70
- ),
71
- 'Vimeo' => array (
72
- 'id' => 'fancybox_enableVimeo',
73
- 'input' => 'checkbox',
74
- 'hide' => true,
75
- 'default' => '',
76
- 'description' => '<strong>' . __('Vimeo','easy-fancybox') . '</strong>'
77
- ),
78
- 'Dailymotion' => array (
79
- 'id' => 'fancybox_enableDailymotion',
80
- 'input' => 'checkbox',
81
- 'hide' => true,
82
- 'default' => '',
83
- 'description' => '<strong>' . __('Dailymotion','easy-fancybox') . '</strong>'
84
- ),
85
- 'iFrame' => array (
86
- 'id' => 'fancybox_enableiFrame',
87
- 'input' => 'checkbox',
88
- 'hide' => true,
89
- 'default' => '',
90
- 'description' => '<strong>' . __('iFrames','easy-fancybox') . '</strong>'
91
- )
92
- ),
93
- 'description' => '<a href="'.$url.'"><strong><em>' . __('For advanced options and support, please get the Easy FancyBox - Pro extension.','easy-fancybox') . '</strong></a>'
94
- ),
95
- 'Overlay' => array (
96
- 'title' => __('Overlay','easy-fancybox'),
97
- 'input' => 'multiple',
98
- 'hide' => true,
99
- 'options' => array(
100
- 'overlayShow' => array (
101
- 'id' => 'fancybox_overlayShow',
102
- 'input' => 'checkbox',
103
- 'noquotes' => true,
104
- 'default' => '1',
105
- 'description' => __('Show the overlay around content opened in FancyBox.','easy-fancybox')
106
- ),
107
- 'hideOnOverlayClick' => array (
108
- 'id' => 'fancybox_hideOnOverlayClick',
109
- 'input' => 'checkbox',
110
- 'noquotes' => true,
111
- 'default' => '1',
112
- 'description' => __('Close FancyBox when overlay is clicked.','easy-fancybox')
113
- ),
114
- 'overlayOpacity' => array (
115
- 'id' => 'fancybox_overlayOpacity',
116
- 'title' => __('Opacity','easy-fancybox'),
117
- 'label_for' => 'fancybox_overlayOpacity',
118
- 'input' => 'number',
119
- 'step' => '0.1',
120
- 'min' => '0',
121
- 'max' => '1',
122
- 'class' => 'small-text',
123
- 'default' => '',
124
- 'description' => __('Value between 0 and 1. ','easy-fancybox') . ' <em>' . __('Default:','easy-fancybox') . ' 0.7</em><br />'
125
- ),
126
- 'overlayColor' => array (
127
- 'id' => 'fancybox_overlayColor',
128
- 'title' => __('Color','easy-fancybox'),
129
- 'label_for' => 'fancybox_overlayColor',
130
- 'input' => 'text',
131
- 'sanitize_callback' => 'colorval',
132
- 'class' => 'small-text',
133
- 'default' => '',
134
- 'description' => __('Enter an HTML color value.','easy-fancybox') . ' <em>' . __('Default:','easy-fancybox') . ' #777</em><br />'
135
- ),
136
- 'overlaySpotlight' => array (
137
- 'id' => 'fancybox_overlaySpotlight',
138
- 'input' => 'checkbox',
139
- 'hide' => true,
140
- 'status' => get_option('fancybox_overlaySpotlight') ? '' : 'disabled',
141
- 'default' => '',
142
- 'description' => __('Spotlight effect','easy-fancybox') . ( get_option('fancybox_overlaySpotlight') ? '' : '. <em><a href="'.$url.'">' . __('Make available &raquo;','easy-fancybox') ) . '</a></em>'
143
- )
144
- )
145
- ),
146
- 'Window' => array (
147
- 'title' => __('Window','easy-fancybox'),
148
- 'input' => 'multiple',
149
- 'hide' => true,
150
- 'options' => array(
151
- 'p1' => array (
152
- 'hide' => true,
153
- 'description' => '<strong>' . __('Appearance','easy-fancybox') . '</strong><br />'
154
- ),
155
- 'showCloseButton' => array (
156
- 'id' => 'fancybox_showCloseButton',
157
- 'input' => 'checkbox',
158
- 'noquotes' => true,
159
- 'default' => '1',
160
- 'description' => __('Show the (X) close button','easy-fancybox')
161
- ),
162
- 'backgroundColor' => array (
163
- 'id' => 'fancybox_backgroundColor',
164
- 'hide' => true,
165
- 'title' => __('Background color','easy-fancybox'),
166
- 'label_for' => 'fancybox_backgroundColor',
167
- 'input' => 'text',
168
- 'sanitize_callback' => 'colorval',
169
- 'status' => 'disabled',
170
- 'class' => 'small-text',
171
- 'default' => '',
172
- 'description' => ''
173
- ),
174
- 'textColor' => array (
175
- 'id' => 'fancybox_textColor',
176
- 'hide' => true,
177
- 'title' => __('Text color','easy-fancybox'),
178
- 'label_for' => 'fancybox_textColor',
179
- 'input' => 'text',
180
- 'sanitize_callback' => 'colorval',
181
- 'status' => 'disabled',
182
- 'class' => 'small-text',
183
- 'default' => '',
184
- 'description' => '<em><a href="'.$url.'">' . __('Make available &raquo;','easy-fancybox') . '</a></em><br />'
185
- ),
186
- 'titleColor' => array (
187
- 'id' => 'fancybox_titleColor',
188
- 'hide' => true,
189
- 'title' => __('Title color','easy-fancybox'),
190
- 'label_for' => 'fancybox_titleColor',
191
- 'input' => 'text',
192
- 'sanitize_callback' => 'colorval',
193
- 'class' => 'small-text',
194
- 'default' => '',
195
- 'description' => ''
196
- ),
197
- 'paddingColor' => array (
198
- 'id' => 'fancybox_paddingColor',
199
- 'hide' => true,
200
- 'title' => __('Border color','easy-fancybox'),
201
- 'label_for' => 'fancybox_paddingColor',
202
- 'input' => 'text',
203
- 'sanitize_callback' => 'colorval',
204
- 'class' => 'small-text',
205
- 'default' => '',
206
- 'description' => '<em>' . __('Default:','easy-fancybox') . ' #000 x #fff</em><br />' . __('Note:','easy-fancybox') . ' ' . __('Use RGBA notation for semi-transparent borders.','easy-fancybox') . ' <em>' . __('Example:','easy-fancybox') . ' rgba(10,10,30,0.7)</em><br />'
207
- ),
208
- 'borderRadius' => array (
209
- 'id' => 'fancybox_borderRadius',
210
- 'hide' => true,
211
- 'title' => __('Border radius','easy-fancybox'),
212
- 'label_for' => 'fancybox_borderRadius',
213
- 'input' => 'number',
214
- 'step' => '1',
215
- 'min' => '0',
216
- 'max' => '99',
217
- 'sanitize_callback' => 'intval',
218
- 'status' => 'disabled',
219
- 'class' => 'small-text',
220
- 'default' => '',
221
- 'description' => '<em><a href="'.$url.'">' . __('Make available &raquo;','easy-fancybox') . '</a></em><br />'
222
- ),
223
-
224
- 'p11' => array (
225
- 'hide' => true,
226
- 'description' => '<br /><strong>' . __('Dimensions','easy-fancybox') . '</strong><br />'
227
- ),
228
- 'width' => array (
229
- 'id' => 'fancybox_width',
230
- 'title' => translate('Width'),
231
- 'label_for' => 'fancybox_width',
232
- 'input' => 'text',
233
- 'sanitize_callback' => 'intval',
234
- 'class' => 'small-text',
235
- 'default' => '',
236
- 'description' => ' '
237
- ),
238
- 'height' => array (
239
- 'id' => 'fancybox_height',
240
- 'title' => translate('Height'),
241
- 'label_for' => 'fancybox_height',
242
- 'input' => 'text',
243
- 'sanitize_callback' => 'intval',
244
- 'class' => 'small-text',
245
- 'default' => '',
246
- 'description' => '<em>' . __('Default:','easy-fancybox') . ' 560 x 340</em><br />' . __('If content size is not set or cannot be determined automatically, these default dimensions will be used.','easy-fancybox') . '<br />'
247
- ),
248
- 'padding' => array (
249
- 'id' => 'fancybox_padding',
250
- 'title' => translate('Border'),
251
- 'label_for' => 'fancybox_padding',
252
- 'input' => 'number',
253
- 'step' => '1',
254
- 'min' => '0',
255
- 'max' => '100',
256
- 'sanitize_callback' => 'intval',
257
- 'class' => 'small-text',
258
- 'default' => '',
259
- 'description' => '<em>' . __('Default:','easy-fancybox') . ' 10</em><br />'
260
- ),
261
- 'margin' => array (
262
- 'id' => 'fancybox_margin',
263
- 'title' => __('Margin','easy-fancybox'),
264
- 'label_for' => 'fancybox_margin',
265
- 'input' => 'number',
266
- 'step' => '1',
267
- 'min' => '20',
268
- 'max' => '80',
269
- 'sanitize_callback' => 'intval',
270
- 'class' => 'small-text',
271
- 'default' => '20',
272
- 'description' => '<em>' . __('Default:','easy-fancybox') . ' 40</em><br />'
273
- ),
274
-
275
- 'p2' => array (
276
- 'hide' => true,
277
- 'description' => '<br /><strong>' . __('Behavior','easy-fancybox') . '</strong><br />'
278
- ),
279
- 'centerOnScroll' => array (
280
- 'id' => 'fancybox_centerOnScroll',
281
- 'input' => 'checkbox',
282
- 'noquotes' => true,
283
- 'default' => '',
284
- 'description' => __('Center while scrolling (disabled on touch devices)','easy-fancybox')
285
- ),
286
- 'enableEscapeButton' => array (
287
- 'id' => 'fancybox_enableEscapeButton',
288
- 'input' => 'checkbox',
289
- 'noquotes' => true,
290
- 'default' => '1',
291
- 'description' => __('Esc key stroke closes FancyBox','easy-fancybox')
292
- ),
293
- 'speedIn' => array (
294
- 'id' => 'fancybox_speedIn',
295
- 'title' => __('Opening speed','easy-fancybox'),
296
- 'label_for' => 'fancybox_speedIn',
297
- 'input' => 'number',
298
- 'step' => '100',
299
- 'min' => '0',
300
- 'max' => '6000',
301
- 'sanitize_callback' => 'intval',
302
- 'class' => 'small-text',
303
- 'default' => '',
304
- ),
305
- 'speedOut' => array (
306
- 'id' => 'fancybox_speedOut',
307
- 'title' => __('Closing speed','easy-fancybox'),
308
- 'label_for' => 'fancybox_speedOut',
309
- 'input' => 'number',
310
- 'step' => '100',
311
- 'min' => '0',
312
- 'max' => '6000',
313
- 'sanitize_callback' => 'intval',
314
- 'class' => 'small-text',
315
- 'default' => '',
316
- 'description' => '<br />' . __('Duration in milliseconds. Higher is slower.','easy-fancybox') . ' <em>' . __('Default:','easy-fancybox') . ' 300</em><br />'
317
- ),
318
- 'mouseWheel' => array (
319
- 'id' => 'fancybox_mouseWheel',
320
- 'hide' => true,
321
- 'input' => 'checkbox',
322
- 'default' => '1',
323
- 'description' => __('Include the Mousewheel jQuery extension script to allow gallery browsing by mousewheel action.','easy-fancybox')
324
- )
325
- )
326
- ),
327
-
328
- 'Miscellaneous' => array (
329
- 'title' => __('Miscellaneous','easy-fancybox'),
330
- 'input' => 'multiple',
331
- 'hide' => true,
332
- 'options' => array(
333
- 'p0' => array (
334
- 'hide' => true,
335
- 'description' => '<strong>' . __('Auto popup','easy-fancybox') . '</strong><br />'
336
- ),
337
- 'autoClick' => array (
338
- 'id' => 'fancybox_autoClick',
339
- 'title' => __('Open on page load','easy-fancybox'),
340
- 'label_for' => 'fancybox_autoClick',
341
- 'hide' => true,
342
- 'input' => 'select',
343
- 'options' => array(
344
- '' => translate('None'),
345
- '1' => __('Link with ID "fancybox-auto"','easy-fancybox'),
346
- ),
347
- 'default' => '1',
348
- 'description' => '<em><a href="'.$url.'">' . __('More options &raquo;','easy-fancybox') . '</a></em><br />'
349
- ),
350
- 'delayClick' => array (
351
- 'id' => 'fancybox_delayClick',
352
- 'title' => __('Delay in milliseconds','easy-fancybox'),
353
- 'label_for' => 'fancybox_delayClick',
354
- 'hide' => true,
355
- 'input' => 'number',
356
- 'step' => '100',
357
- 'min' => '0',
358
- 'max' => '',
359
- 'sanitize_callback' => 'intval',
360
- 'class' => 'small-text',
361
- 'default' => '1000',
362
- 'description' => ' <em>' . __('Default:','easy-fancybox') . ' 1000</em><br />'
363
- ),
364
- 'jqCookie' => array (
365
- 'id' => '',
366
- 'title' => __('Hide popup after first visit?','easy-fancybox'),
367
- 'hide' => true,
368
- 'input' => 'select',
369
- 'status' => 'disabled',
370
- 'default' => '0',
371
- 'sanitize_callback' => 'intval',
372
- 'options' => array(
373
- '0' => translate('No'),
374
- '1' => __('1 Day','easy-fancybox'),
375
- '7' => __('1 Week','easy-fancybox'),
376
- '30' => __('1 Month','easy-fancybox'),
377
- '365' => __('1 Year','easy-fancybox')
378
- ),
379
- 'description' => ' <em><a href="'.$url.'">' . __('Make available &raquo;','easy-fancybox') . '</a></em><br />'
380
- ),
381
- 'cookiePath' => array (
382
- 'id' => '',
383
- 'default' => '',
384
- 'hide' => true
385
- ),
386
- 'p1' => array (
387
- 'hide' => true,
388
- 'description' => '<br /><strong>' . __('Browser & device compatibility','easy-fancybox') . '</strong><br />'
389
- ),
390
- 'minViewportWidth' => array (
391
- 'id' => 'fancybox_minViewportWidth',
392
- 'title' => __('Minimum browser/device viewport width','easy-fancybox'),
393
- 'label_for' => 'fancybox_minViewportWidth',
394
- 'input' => 'number',
395
- 'step' => '1',
396
- 'min' => '320',
397
- 'max' => '900',
398
- 'sanitize_callback' => 'intval',
399
- 'class' => 'small-text',
400
- 'default' => '',
401
- 'description' => __('(leave empty to ignore)','easy-fancybox') . '<br/>'
402
- ),
403
- /* 'forceNewtab' => array (
404
- 'id' => 'fancybox_forceNewtab',
405
- 'input' => 'checkbox',
406
- 'hide' => true,
407
- 'default' => '1',
408
- 'description' => __('Make media links open in a new tab when viewport falls below minimum width (above)','easy-fancybox')
409
- ),
410
- */
411
- 'compatIE8' => array (
412
- 'id' => 'fancybox_compatIE8',
413
- 'input' => 'checkbox',
414
- 'hide' => true,
415
- 'default' => '',
416
- 'description' => __('Include IE 8 compatibility style rules','easy-fancybox')
417
- ),
418
-
419
- 'p2' => array (
420
- 'hide' => true,
421
- 'description' => '<br /><strong>' . __('Theme & plugins compatibility','easy-fancybox') . '</strong><br />'
422
- . __('Try to deactivate all conflicting light box scripts in your theme or other plugins. If this is not possible, try a higher script priority number which means scripts are added later, wich may allow them to override conflicting scripts. A lower priority number, excluding WordPress standard jQuery, or even moving the plugin scripts to the header may work in cases where there are blocking errors occuring in other script.','easy-fancybox') . '<br /><br />'
423
- ),
424
- 'scriptPriority' => array (
425
- 'id' => 'fancybox_scriptPriority',
426
- 'title' => __('FancyBox script priority','easy-fancybox'),
427
- 'label_for' => 'fancybox_scriptPriority',
428
- 'input' => 'number',
429
- 'step' => '1',
430
- 'min' => '-999',
431
- 'max' => '999',
432
- 'sanitize_callback' => 'intval',
433
- 'class' => 'small-text',
434
- 'default' => '10',
435
- 'description' => __('Default priority is 10.','easy-fancybox') . ' ' . __('Higher is later.','easy-fancybox') . '<br/>'
436
- ),
437
- 'noFooter' => array (
438
- 'id' => 'fancybox_noFooter',
439
- 'input' => 'checkbox',
440
- 'hide' => true,
441
- 'default' => '',
442
- 'description' => __('Move scripts from footer to theme head section (not recommended for site load times!)','easy-fancybox')
443
- ),
444
- 'nojQuery' => array (
445
- 'id' => 'fancybox_nojQuery',
446
- 'input' => 'checkbox',
447
- 'hide' => true,
448
- 'default' => '',
449
- 'description' => __('Do not include standard WordPress jQuery library (do this only if you are sure jQuery is included from another source!)','easy-fancybox')
450
- ),
451
- 'pre45Compat' => array (
452
- 'id' => 'fancybox_pre45Compat',
453
- 'input' => 'checkbox',
454
- 'hide' => true,
455
- 'default' => function_exists( 'wp_add_inline_script' ) ? '' : '1',
456
- 'description' => __('Do not use wp_add_inline_script/style functions (may solve issues with older script minification plugins)','easy-fancybox')
457
- ),
458
- 'p3' => array (
459
- 'hide' => true,
460
- 'description' => '<br /><strong>' . __('Advanced','easy-fancybox') . '</strong><br />'
461
- ),
462
- 'metaData' => array (
463
- 'id' => 'fancybox_metaData',
464
- 'hide' => true,
465
- 'input' => 'checkbox',
466
- 'status' => get_option('fancybox_metaData') ? '' : 'disabled',
467
- 'default' => '',
468
- 'description' => __('Include the Metadata jQuery extension script to allow passing custom parameters via link class.','easy-fancybox') . ( get_option('fancybox_metaData') ? '' : '. <em><a href="'.$url.'">' . __('Make available &raquo;','easy-fancybox') ) . '</a></em>'
469
- )
470
- )
471
- )
472
- )
473
- ),
474
-
475
- 'IMG' => array(
476
- 'title' => __('Images','easy-fancybox'),
477
- 'input' => 'multiple',
478
- 'options' => array(
479
- 'intro' => array (
480
- 'hide' => true,
481
- 'description' => __('To make images open in an overlay, add their extension to the Autodetect field or use the class "fancybox" for its link. Clear field to switch off all autodetection.','easy-fancybox') . '<br />'
482
- ),
483
- 'tag' => array (
484
- 'hide' => true,
485
- 'default' => 'a.fancybox,area.fancybox,li.fancybox a'
486
- ),
487
- 'class' => array (
488
- 'hide' => true,
489
- 'default' => 'fancybox image'
490
- ),
491
- 'autoAttribute' => array (
492
- 'id' => 'fancybox_autoAttribute',
493
- 'title' => __('Autodetect','easy-fancybox'),
494
- 'label_for' => 'fancybox_autoAttribute',
495
- 'input' => 'text',
496
- 'class' => 'regular-text',
497
- 'hide' => true,
498
- 'default' => '.jpg .jpeg .png .webp',
499
- 'selector' => 'href*=',
500
- 'description' => ' <em>' . __('Example:','easy-fancybox') . ' .jpg .jpeg .png .gif</em><br />'
501
- ),
502
- 'autoAttributeLimit' => array (
503
- 'id' => 'fancybox_autoAttributeLimit',
504
- 'title' => __('Apply to','easy-fancybox'),
505
- 'label_for' => 'fancybox_autoAttributeLimit',
506
- 'hide' => true,
507
- 'input' => 'select',
508
- 'options' => array(
509
- '' => __('All image links', 'easy-fancybox')
510
- ),
511
- 'default' => '',
512
- 'description' => '<em><a href="'.$url.'">' . __('More options &raquo;','easy-fancybox') . '</a></em><br />'
513
- ),
514
- 'type' => array (
515
- 'id' => 'fancybox_classType',
516
- 'title' => __('Force FancyBox to treat all media linked with class="fancybox" as images?','easy-fancybox'),
517
- 'label_for' => 'fancybox_classType',
518
- 'input' => 'select',
519
- 'options' => array(
520
- 'image' => translate('Yes'),
521
- '' => translate('No')
522
- ),
523
- 'default' => get_option('fancybox_enableInline') ? 'image' : '',
524
- 'description' => '<br/>'
525
- ),
526
- 'p2' => array (
527
- 'hide' => true,
528
- 'description' => '<br /><strong>' . __('Behavior','easy-fancybox') . '</strong><br />'
529
- ),
530
- 'transitionIn' => array (
531
- 'id' => 'fancybox_transitionIn',
532
- 'title' => __('Transition In','easy-fancybox'),
533
- 'label_for' => 'fancybox_transitionIn',
534
- 'input' => 'select',
535
- 'options' => array(
536
- 'none' => translate('None'),
537
- '' => __('Fade','easy-fancybox'),
538
- 'elastic' => __('Elastic','easy-fancybox'),
539
- ),
540
- 'default' => 'elastic',
541
- 'description' => ' '
542
- ),
543
- 'easingIn' => array (
544
- 'id' => 'fancybox_easingIn',
545
- 'title' => __('Easing In','easy-fancybox'),
546
- 'label_for' => 'fancybox_easingIn',
547
- 'input' => 'select',
548
- 'options' => array(
549
- 'linear' => __('Linear','easy-fancybox'),
550
- '' => __('Swing','easy-fancybox'),
551
- 'easeInBack' => __('easeInBack','easy-fancybox'),
552
- 'easeOutBack' => __('easeOutBack','easy-fancybox')
553
- ),
554
- 'default' => 'easeOutBack',
555
- 'description' => ' <em><a href="'.$url.'">' . __('More options &raquo;','easy-fancybox') . '</a></em><br />'
556
- ),
557
- 'transitionOut' => array (
558
- 'id' => 'fancybox_transitionOut',
559
- 'title' => __('Transition Out','easy-fancybox'),
560
- 'label_for' => 'fancybox_transitionOut',
561
- 'input' => 'select',
562
- 'options' => array(
563
- 'none' => translate('None'),
564
- '' => __('Fade','easy-fancybox'),
565
- 'elastic' => __('Elastic','easy-fancybox'),
566
- ),
567
- 'default' => 'elastic',
568
- 'description' => ' '
569
- ),
570
- 'easingOut' => array (
571
- 'id' => 'fancybox_easingOut',
572
- 'title' => __('Easing Out','easy-fancybox'),
573
- 'label_for' => 'fancybox_easingOut',
574
- 'input' => 'select',
575
- 'options' => array(
576
- 'linear' => __('Linear','easy-fancybox'),
577
- '' => __('Swing','easy-fancybox'),
578
- 'easeInBack' => __('easeInBack','easy-fancybox'),
579
- 'easeOutBack' => __('easeOutBack','easy-fancybox')
580
- ),
581
- 'default' => 'easeInBack',
582
- 'description' => ' <em><a href="'.$url.'">' . __('More options &raquo;','easy-fancybox') . '</a></em><br />' . __('Note:','easy-fancybox') . ' ' . __('Easing effects only apply when Transition is set to Elastic. ','easy-fancybox') . '<br /><br />'
583
- ),
584
- 'opacity' => array (
585
- 'id' => 'fancybox_opacity',
586
- 'input' => 'checkbox',
587
- 'noquotes' => true,
588
- 'default' => '',
589
- 'description' => __('Transparency fade during elastic transition. CAUTION: Use only when at least Transition In is set to Elastic!','easy-fancybox')
590
- ),
591
- 'hideOnContentClick' => array (
592
- 'id' => 'fancybox_hideOnContentClick',
593
- 'input' => 'checkbox',
594
- 'noquotes' => true,
595
- 'default' => '',
596
- 'description' => __('Close FancyBox when content is clicked','easy-fancybox')
597
- ),
598
- 'p1' => array (
599
- 'hide' => true,
600
- 'description' => '<br /><strong>' . __('Appearance','easy-fancybox') . '</strong><br />'
601
- ),
602
- 'titleShow' => array (
603
- 'id' => 'fancybox_titleShow',
604
- 'input' => 'checkbox',
605
- 'noquotes' => true,
606
- 'default' => '1',
607
- 'description' => __('Show title.','easy-fancybox') . ' ' . __('FancyBox will try to get a title from the link or thumbnail title attributes.','easy-fancybox')
608
- ),
609
- 'titlePosition' => array (
610
- 'id' => 'fancybox_titlePosition',
611
- 'title' => __('Title Position','easy-fancybox'),
612
- 'label_for' => 'fancybox_titlePosition',
613
- 'input' => 'select',
614
- 'options' => array(
615
- '' => __('Float','easy-fancybox'),
616
- 'outside' => __('Outside','easy-fancybox'),
617
- 'inside' => __('Inside','easy-fancybox'),
618
- 'over' => __('Overlay','easy-fancybox')
619
- ),
620
- 'default' => 'over',
621
- 'description' => '<br />'
622
- ),
623
- 'titleFromAlt' => array (
624
- 'id' => 'fancybox_titleFromAlt',
625
- 'input' => 'checkbox',
626
- 'noquotes' => true,
627
- 'default' => '1',
628
- 'description' => __('Allow title from thumbnail alt attribute.','easy-fancybox')
629
- ),
630
- 'onStart' => array (
631
- 'id' => '',
632
- 'title' => __('Advanced','easy-fancybox'),
633
- 'input' => 'select',
634
- 'status' => 'disabled',
635
- 'options' => array(
636
- '' => __('Hide/show title on mouse hover action','easy-fancybox')
637
- ),
638
- 'default' => '',
639
- 'description' => '<em><a href="'.$url.'">' . __('Make available &raquo;','easy-fancybox') . '</a></em><br />'
640
- ),
641
- 'p3' => array (
642
- 'hide' => true,
643
- 'description' => '<br /><strong>' . __('Gallery','easy-fancybox') . '</strong><br />'
644
- ),
645
- 'autoGallery' => array (
646
- 'id' => 'fancybox_autoGallery',
647
- 'title' => __('Autogallery','easy-fancybox'),
648
- 'label_for' => 'fancybox_autoGallery',
649
- 'hide' => true,
650
- 'input' => 'select',
651
- 'options' => array(
652
- '' => translate('Disabled'),
653
- '1' => __('WordPress galleries only','easy-fancybox'),
654
- '2' => __('All in one gallery','easy-fancybox')
655
- ),
656
- 'default' => '1',
657
- 'description' => '<em><a href="'.$url.'">' . __('More options &raquo;','easy-fancybox') . '</a></em><br />' . __('Note:','easy-fancybox') . ' ' . __('When disabled, you can use the rel attribute to manually group image links together.','easy-fancybox') . '<br /><br />'
658
- ),
659
- 'showNavArrows' => array (
660
- 'id' => 'fancybox_showNavArrows',
661
- 'input' => 'checkbox',
662
- 'noquotes' => true,
663
- 'default' => '1',
664
- 'description' => __('Show the gallery navigation arrows','easy-fancybox')
665
- ),
666
- 'enableKeyboardNav' => array (
667
- 'id' => 'fancybox_enableKeyboardNav',
668
- 'input' => 'checkbox',
669
- 'noquotes' => true,
670
- 'default' => '1',
671
- 'description' => __('Arrow key strokes browse the gallery','easy-fancybox')
672
- ),
673
- 'cyclic' => array (
674
- 'id' => 'fancybox_cyclic',
675
- 'input' => 'checkbox',
676
- 'noquotes' => true,
677
- 'default' => '',
678
- 'description' => __('Make galleries cyclic, allowing you to keep pressing next/back.','easy-fancybox')
679
- ),
680
- 'changeSpeed' => array (
681
- 'id' => 'fancybox_changeSpeed',
682
- 'title' => __('Change speed','easy-fancybox'),
683
- 'label_for' => 'fancybox_changeSpeed',
684
- 'input' => 'number',
685
- 'step' => '1',
686
- 'min' => '0',
687
- 'max' => '6000',
688
- 'sanitize_callback' => 'intval',
689
- 'class' => 'small-text',
690
- 'default' => '',
691
- ),
692
- 'changeFade' => array (
693
- 'id' => 'fancybox_changeFade',
694
- 'title' => __('Fade speed','easy-fancybox'),
695
- 'label_for' => 'fancybox_changeFade',
696
- 'input' => 'number',
697
- 'step' => '1',
698
- 'min' => '0',
699
- 'max' => '6000',
700
- 'sanitize_callback' => 'intval',
701
- 'class' => 'small-text',
702
- 'default' => '',
703
- 'description' => '<br />' . __('Duration in milliseconds. Higher is slower.','easy-fancybox') . ' <em>' . __('Default:','easy-fancybox') . ' 300</em><br /><br />'
704
- ),
705
- 'autoSelector' => array (
706
- 'id' => 'fancybox_autoSelector',
707
- 'hide' => true,
708
- 'input' => 'hidden',
709
- 'default' => 'div.gallery,div.wp-block-gallery,div.tiled-gallery' // add div.tiled-gallery for Tiled Galleries support
710
- ),
711
- 'onComplete' => array (
712
- 'id' => '',
713
- 'title' => __('Advanced','easy-fancybox'),
714
- 'input' => 'select',
715
- 'status' => 'disabled',
716
- 'options' => array(
717
- '' => __('Slideshow','easy-fancybox')
718
- ),
719
- 'default' => '',
720
- 'description' => '<em><a href="'.$url.'">' . __('Make available &raquo;','easy-fancybox') . '</a></em>'
721
- ),
722
- /* 'titleFormat' => array (
723
- 'id' => 'fancybox_titleFormat',
724
- 'title' => __('Title format','easy-fancybox'),
725
- 'label_for' => 'fancybox_titleFormat',
726
- 'input' => 'select',
727
- 'options' => array(
728
- '' => __('Default FancyBox style','easy-fancybox'),
729
- 'function(title, currentArray, currentIndex, currentOpts) { return \'<div style="font-face:Arial,sans-serif;text-align:left"><span style="float:right;font-size:large"><a href="javascript:;" onclick="$.fancybox.close();">' . __('Close','easy-fancybox') . ' <img src="' . plugins_url(FANCYBOX_SUBDIR, __FILE__) . '/fancybox/fancy_close.png" /></a></span>\' + (title && title.length ? \'<b style="display:block;margin-right:80px">\' + title + \'</b>\' : \'\' ) + \'' . __('Image','easy-fancybox') . '\' + (currentIndex + 1) + \' ' . __('of','easy-fancybox') . ' \' + currentArray.length + \'</div>\';
730
- }' => __('Mimic Lightbox2 style','easy-fancybox'),
731
- ),
732
- 'noquotes' => true,
733
- 'default' => '',
734
- 'description' => '<br />' . __('To improve Lightbox2 style disable Show close button and set titleposition to Inside or Outside','easy-fancybox') . '<br />'
735
- ),*/
736
- )
737
- ),
738
-
739
- 'Inline' => array(
740
- 'title' => __('Inline content','easy-fancybox'),
741
- 'input' => 'multiple',
742
- 'options' => array(
743
- 'intro' => array (
744
- 'hide' => true,
745
- 'description' => __('To make inline content open in an overlay, wrap that content in a div with a unique ID, create a link with target "#uniqueID" and give it a class "fancybox-inline" attribute.','easy-fancybox') . '<br /><br />'
746
- ),
747
- 'tag' => array (
748
- 'hide' => true,
749
- 'default' => 'a.fancybox-inline,area.fancybox-inline,li.fancybox-inline a'
750
- ),
751
- 'class' => array (
752
- 'hide' => true,
753
- 'default' => 'fancybox-inline'
754
- ),
755
- 'type' => array (
756
- 'default' => 'inline'
757
- ),
758
- 'autoDimensions' => array (
759
- 'id' => 'fancybox_autoDimensions',
760
- 'input' => 'checkbox',
761
- 'noquotes' => true,
762
- 'default' => '1',
763
- 'description' => __('Try to adjust size to inline/html content. If unchecked the default dimensions will be used.','easy-fancybox') . ''
764
- ),
765
- 'scrolling' => array (
766
- 'id' => 'fancybox_InlineScrolling',
767
- 'title' => __('Scrolling','easy-fancybox'),
768
- 'label_for' => 'fancybox_InlineScrolling',
769
- 'input' => 'select',
770
- 'options' => array(
771
- 'auto' => __('Auto','easy-fancybox'),
772
- 'yes' => __('Always','easy-fancybox'),
773
- 'no' => __('Never','easy-fancybox')
774
- ),
775
- 'default' => 'no',
776
- 'description' => __('Define scrolling and scrollbar visibility.','easy-fancybox') . '<br /><br />'
777
- ),
778
- 'transitionIn' => array (
779
- 'id' => 'fancybox_transitionInInline',
780
- 'title' => __('Transition In','easy-fancybox'),
781
- 'label_for' => 'fancybox_transitionInInline',
782
- 'input' => 'select',
783
- 'options' => array(
784
- 'none' => translate('None'),
785
- '' => __('Fade','easy-fancybox'),
786
- 'elastic' => __('Elastic','easy-fancybox'),
787
- ),
788
- 'default' => '',
789
- 'description' => ' '
790
- ),
791
- 'easingIn' => array (
792
- 'id' => 'fancybox_easingInInline',
793
- 'title' => __('Easing In','easy-fancybox'),
794
- 'label_for' => 'fancybox_easingInInline',
795
- 'input' => 'select',
796
- 'options' => array(
797
- 'linear' => __('Linear','easy-fancybox'),
798
- '' => __('Swing','easy-fancybox'),
799
- 'easeInBack' => __('easeInBack','easy-fancybox'),
800
- 'easeOutBack' => __('easeOutBack','easy-fancybox')
801
- ),
802
- 'default' => 'easeOutBack',
803
- 'description' => ' <em><a href="'.$url.'">' . __('More options &raquo;','easy-fancybox') . '</a></em><br />'
804
- ),
805
- 'transitionOut' => array (
806
- 'id' => 'fancybox_transitionOutInline',
807
- 'title' => __('Transition Out','easy-fancybox'),
808
- 'label_for' => 'fancybox_transitionOutInline',
809
- 'input' => 'select',
810
- 'options' => array(
811
- 'none' => translate('None'),
812
- '' => __('Fade','easy-fancybox'),
813
- 'elastic' => __('Elastic','easy-fancybox'),
814
- ),
815
- 'default' => '',
816
- 'description' => ' '
817
- ),
818
- 'easingOut' => array (
819
- 'id' => 'fancybox_easingOutInline',
820
- 'title' => __('Easing Out','easy-fancybox'),
821
- 'label_for' => 'fancybox_easingOutInline',
822
- 'input' => 'select',
823
- 'options' => array(
824
- 'linear' => __('Linear','easy-fancybox'),
825
- '' => __('Swing','easy-fancybox'),
826
- 'easeInBack' => __('easeInBack','easy-fancybox'),
827
- 'easeOutBack' => __('easeOutBack','easy-fancybox')
828
- ),
829
- 'default' => 'easeInBack',
830
- 'description' => ' <em><a href="'.$url.'">' . __('More options &raquo;','easy-fancybox') . '</a></em><br />' . __('Note:','easy-fancybox') . ' ' . __('Easing effects only apply when Transition is set to Elastic. ','easy-fancybox') . '<br /><br />'
831
- ),
832
- 'opacity' => array (
833
- 'id' => 'fancybox_opacityInline',
834
- 'input' => 'checkbox',
835
- 'noquotes' => true,
836
- 'default' => '',
837
- 'description' => __('Transparency fade during elastic transition. CAUTION: Use only when at least Transition In is set to Elastic!','easy-fancybox')
838
- ),
839
- 'hideOnContentClick' => array (
840
- 'id' => 'fancybox_hideOnContentClickInline',
841
- 'input' => 'checkbox',
842
- 'noquotes' => true,
843
- 'default' => '',
844
- 'description' => __('Close FancyBox when content is clicked','easy-fancybox')
845
- )
846
- )
847
- ),
848
-
849
- 'PDF' => array(
850
- 'title' => __('PDF','easy-fancybox'),
851
- 'input' => 'multiple',
852
- 'options' => array(
853
- 'intro' => array (
854
- 'hide' => true,
855
- 'description' => __('To make any PDF document file open in an overlay, switch on Autodetect or use the class "fancybox-pdf" for its link.','easy-fancybox') . '<br />'
856
- ),
857
- 'autoAttribute' => array (
858
- 'id' => 'fancybox_autoAttributePDF',
859
- 'input' => 'checkbox',
860
- 'hide' => true,
861
- 'default' => '1',
862
- 'selector' => 'a[href*=".pdf"],area[href*=".pdf"],a[href*=".PDF"],area[href*=".PDF"]',
863
- 'description' => __('Autodetect','easy-fancybox')
864
- ),
865
- 'tag' => array (
866
- 'hide' => true,
867
- 'default' => 'a.fancybox-pdf,area.fancybox-pdf,li.fancybox-pdf a'
868
- ),
869
- 'class' => array (
870
- 'hide' => true,
871
- 'default' => 'fancybox-pdf'
872
- ),
873
- 'type' => array (
874
- 'default' => 'iframe'
875
- ),
876
- 'onStart' => array (
877
- 'id' => 'fancybox_PDFonStart',
878
- 'noquotes' => true,
879
- 'title' => __('Embed with','easy-fancybox'),
880
- 'label_for' => 'fancybox_PDFtitlePosition',
881
- 'input' => 'select',
882
- 'options' => array(
883
- 'function(a,i,o){o.type=\'pdf\';}' => __('Object tag (plus fall-back link)','easy-fancybox'),
884
- 'function(a,i,o){o.content=\'<embed src="\'+a[i].href+\'" type="application/pdf" height="100%" width="100%" />\'}' => __('Embed tag','easy-fancybox'),
885
- '' => __('iFrame tag (let browser decide)','easy-fancybox'),
886
- 'function(a,i,o){o.href=\'https://docs.google.com/viewer?embedded=true&url=\'+a[i].href;}' => __('Google Docs Viewer (external)','easy-fancybox')
887
- ),
888
- 'default' => '',
889
- // 'function(a,i,o){o.content=\'<object data="\'+a[i].href+\'" type="application/pdf" height="100%" width="100%"><a href="\'+a[i].href+\'" style="display:block;position:absolute;top:48%;width:100%;text-align:center">\'+jQuery(a[i]).html()+\'</a></object>\'}'
890
- // 'function(a, i, o) { o.content = \'<embed src="\' + a[i].href + \'#toolbar=1&navpanes=0&nameddest=self&page=1&view=FitH,0&zoom=80,0,0" type="application/pdf" height="100%" width="100%" />\' }'
891
- 'description' => __('Note:','easy-fancybox') . ' ' . __('External viewers have bandwidth, usage rate and and file size limits.','easy-fancybox') . '<br /><br />' //' <em><a href="'.$url.'">' . __('More options &raquo;','easy-fancybox') . '</a></em><br /><br />'
892
- ),
893
- 'width' => array (
894
- 'id' => 'fancybox_PDFwidth',
895
- 'title' => translate('Width'),
896
- 'label_for' => 'fancybox_PDFwidth',
897
- 'input' => 'text',
898
- 'sanitize_callback' => 'intval',
899
- 'class' => 'small-text',
900
- 'default' => '90%',
901
- 'description' => ' '
902
- ),
903
- 'height' => array (
904
- 'id' => 'fancybox_PDFheight',
905
- 'title' => translate('Height'),
906
- 'label_for' => 'fancybox_PDFheight',
907
- 'input' => 'text',
908
- 'sanitize_callback' => 'intval',
909
- 'class' => 'small-text',
910
- 'default' => '90%'
911
- ),
912
- 'padding' => array (
913
- 'id' => 'fancybox_PDFpadding',
914
- 'title' => translate('Border'),
915
- 'label_for' => 'fancybox_PDFpadding',
916
- 'input' => 'number',
917
- 'step' => '1',
918
- 'min' => '0',
919
- 'max' => '100',
920
- 'sanitize_callback' => 'intval',
921
- 'class' => 'small-text',
922
- 'default' => '10',
923
- 'description' => '<br /><br />'
924
- ),
925
- 'titleShow' => array (
926
- 'id' => 'fancybox_PDFtitleShow',
927
- 'input' => 'checkbox',
928
- 'noquotes' => true,
929
- 'default' => '',
930
- 'description' => __('Show title.','easy-fancybox') . ' ' . __('FancyBox will try to get a title from the link or thumbnail title attributes.','easy-fancybox')
931
- ),
932
- 'titlePosition' => array (
933
- 'id' => 'fancybox_PDFtitlePosition',
934
- 'title' => __('Title Position','easy-fancybox'),
935
- 'label_for' => 'fancybox_PDFtitlePosition',
936
- 'input' => 'select',
937
- 'options' => array(
938
- 'float' => __('Float','easy-fancybox'),
939
- 'outside' => __('Outside','easy-fancybox'),
940
- 'inside' => __('Inside','easy-fancybox')
941
- ),
942
- 'default' => 'float',
943
- 'description' => '<br />'
944
- ),
945
- 'titleFromAlt' => array (
946
- 'id' => 'fancybox_PDFtitleFromAlt',
947
- 'input' => 'checkbox',
948
- 'noquotes' => true,
949
- 'default' => '1',
950
- 'description' => __('Allow title from thumbnail alt attribute.','easy-fancybox')
951
- ),
952
- 'autoDimensions' => array (
953
- 'noquotes' => true,
954
- 'default' => 'false'
955
- ),
956
- 'scrolling' => array (
957
- 'default' => 'no',
958
- ),
959
- )
960
- ),
961
-
962
- 'SWF' => array(
963
- 'title' => __('SWF','easy-fancybox'),
964
- 'input' => 'multiple',
965
- 'options' => array(
966
- 'intro' => array (
967
- 'hide' => true,
968
- 'description' => __('To make any Flash (.swf) file open in an overlay, switch on Autodetect or use the class "fancybox-swf" for its link.','easy-fancybox') . '<br />'
969
- ),
970
- 'autoAttribute' => array (
971
- 'id' => 'fancybox_autoAttributeSWF',
972
- 'input' => 'checkbox',
973
- 'hide' => true,
974
- 'default' => '1',
975
- 'selector' => 'a[href*=".swf"],area[href*=".swf"],a[href*=".SWF"],area[href*=".SWF"]',
976
- 'description' => __('Autodetect','easy-fancybox') . '<br />'
977
- ),
978
- 'tag' => array (
979
- 'hide' => true,
980
- 'default' => 'a.fancybox-swf,area.fancybox-swf,li.fancybox-swf a'
981
- ),
982
- 'class' => array (
983
- 'hide' => true,
984
- 'default' => 'fancybox-swf'
985
- ),
986
- 'type' => array(
987
- 'default' => 'swf'
988
- ),
989
- 'width' => array (
990
- 'id' => 'fancybox_SWFWidth',
991
- 'title' => translate('Width'),
992
- 'label_for' => 'fancybox_SWFWidth',
993
- 'input' => 'text',
994
- 'sanitize_callback' => 'intval',
995
- 'class' => 'small-text',
996
- 'options' => array(),
997
- 'default' => '680',
998
- 'description' => ' '
999
- ),
1000
- 'height' => array (
1001
- 'id' => 'fancybox_SWFHeight',
1002
- 'title' => translate('Height'),
1003
- 'label_for' => 'fancybox_SWFHeight',
1004
- 'input' => 'text',
1005
- 'sanitize_callback' => 'intval',
1006
- 'class' => 'small-text',
1007
- 'options' => array(),
1008
- 'default' => '495',
1009
- ),
1010
- 'padding' => array (
1011
- 'id' => 'fancybox_SWFpadding',
1012
- 'title' => translate('Border'),
1013
- 'label_for' => 'fancybox_SWFpadding',
1014
- 'input' => 'number',
1015
- 'step' => '1',
1016
- 'min' => '0',
1017
- 'max' => '100',
1018
- 'sanitize_callback' => 'intval',
1019
- 'class' => 'small-text',
1020
- 'default' => '0',
1021
- 'description' => '<br /><br />'
1022
- ),
1023
- 'titleShow' => array (
1024
- 'id' => 'fancybox_SWFtitleShow',
1025
- 'input' => 'checkbox',
1026
- 'noquotes' => true,
1027
- 'default' => '',
1028
- 'description' => __('Show title.','easy-fancybox') . ' ' . __('FancyBox will try to get a title from the link or thumbnail title attributes.','easy-fancybox')
1029
- ),
1030
- 'titlePosition' => array (
1031
- 'id' => 'fancybox_SWFtitlePosition',
1032
- 'title' => __('Title Position','easy-fancybox'),
1033
- 'label_for' => 'fancybox_SWFtitlePosition',
1034
- 'input' => 'select',
1035
- 'options' => array(
1036
- 'float' => __('Float','easy-fancybox'),
1037
- 'outside' => __('Outside','easy-fancybox'),
1038
- 'inside' => __('Inside','easy-fancybox')
1039
- ),
1040
- 'default' => 'float',
1041
- 'description' => '<br />'
1042
- ),
1043
- 'titleFromAlt' => array (
1044
- 'id' => 'fancybox_SWFtitleFromAlt',
1045
- 'input' => 'checkbox',
1046
- 'noquotes' => true,
1047
- 'default' => '1',
1048
- 'description' => __('Allow title from thumbnail alt attribute.','easy-fancybox')
1049
- ),
1050
- 'swf' => array (
1051
- 'noquotes' => true,
1052
- 'default' => '{\'wmode\':\'opaque\',\'allowfullscreen\':true}'
1053
- )
1054
- )
1055
- ),
1056
-
1057
- 'SVG' => array(
1058
- 'title' => __('SVG','easy-fancybox'),
1059
- 'input' => 'multiple',
1060
- 'options' => array(
1061
- 'intro' => array (
1062
- 'hide' => true,
1063
- 'description' => __('To make any SVG (.svg) file open in an overlay, switch on Autodetect or use the class "fancybox-svg" for its link.','easy-fancybox') . '<br />'
1064
- ),
1065
- 'autoAttribute' => array (
1066
- 'id' => 'fancybox_autoAttributeSVG',
1067
- 'input' => 'checkbox',
1068
- 'hide' => true,
1069
- 'default' => '1',
1070
- 'selector' => 'a[href*=".svg"],area[href*=".svg"],a[href*=".SVG"],area[href*=".SVG"]',
1071
- 'description' => __('Autodetect','easy-fancybox') . '<br />'
1072
- ),
1073
- 'tag' => array (
1074
- 'hide' => true,
1075
- 'default' => 'a.fancybox-svg,area.fancybox-svg,li.fancybox-svg a'
1076
- ),
1077
- 'class' => array (
1078
- 'hide' => true,
1079
- 'default' => 'fancybox-svg'
1080
- ),
1081
- 'type' => array(
1082
- 'default' => 'svg'
1083
- ),
1084
- 'width' => array (
1085
- 'id' => 'fancybox_SVGWidth',
1086
- 'title' => translate('Width'),
1087
- 'label_for' => 'fancybox_SVGWidth',
1088
- 'input' => 'text',
1089
- 'sanitize_callback' => 'intval',
1090
- 'class' => 'small-text',
1091
- 'options' => array(),
1092
- 'default' => '680',
1093
- 'description' => ' '
1094
- ),
1095
- 'height' => array (
1096
- 'id' => 'fancybox_SVGHeight',
1097
- 'title' => translate('Height'),
1098
- 'label_for' => 'fancybox_SVGHeight',
1099
- 'input' => 'text',
1100
- 'sanitize_callback' => 'intval',
1101
- 'class' => 'small-text',
1102
- 'options' => array(),
1103
- 'default' => '495',
1104
- ),
1105
- 'padding' => array (
1106
- 'id' => 'fancybox_SVGpadding',
1107
- 'title' => translate('Border'),
1108
- 'label_for' => 'fancybox_SVGpadding',
1109
- 'input' => 'number',
1110
- 'step' => '1',
1111
- 'min' => '0',
1112
- 'max' => '100',
1113
- 'sanitize_callback' => 'intval',
1114
- 'class' => 'small-text',
1115
- 'default' => '0',
1116
- 'description' => '<br /><br />'
1117
- ),
1118
- 'titleShow' => array (
1119
- 'id' => 'fancybox_SVGtitleShow',
1120
- 'input' => 'checkbox',
1121
- 'noquotes' => true,
1122
- 'default' => '',
1123
- 'description' => __('Show title.','easy-fancybox') . ' ' . __('FancyBox will try to get a title from the link or thumbnail title attributes.','easy-fancybox')
1124
- ),
1125
- 'titlePosition' => array (
1126
- 'id' => 'fancybox_SVGtitlePosition',
1127
- 'title' => __('Title Position','easy-fancybox'),
1128
- 'label_for' => 'fancybox_SVGtitlePosition',
1129
- 'input' => 'select',
1130
- 'options' => array(
1131
- 'float' => __('Float','easy-fancybox'),
1132
- 'outside' => __('Outside','easy-fancybox'),
1133
- 'inside' => __('Inside','easy-fancybox')
1134
- //,'over' => __('Overlay','easy-fancybox')
1135
- ),
1136
- 'default' => 'float',
1137
- 'description' => '<br />'
1138
- ),
1139
- 'titleFromAlt' => array (
1140
- 'id' => 'fancybox_SVGtitleFromAlt',
1141
- 'input' => 'checkbox',
1142
- 'noquotes' => true,
1143
- 'default' => '1',
1144
- 'description' => __('Allow title from thumbnail alt attribute.','easy-fancybox')
1145
- ),
1146
- 'svg' => array (
1147
- 'noquotes' => true,
1148
- 'default' => '{\'wmode\':\'opaque\',\'allowfullscreen\':true}'
1149
- )
1150
- )
1151
- ),
1152
-
1153
- 'YouTube' => array(
1154
- 'title' => __('YouTube','easy-fancybox'),
1155
- 'input' => 'multiple',
1156
- 'options' => array(
1157
- 'intro' => array (
1158
- 'hide' => true,
1159
- 'description' => __('To make any YouTube movie open in an overlay, switch on Autodetect or use the class "fancybox-youtube" for its link.','easy-fancybox') . '<br />'
1160
- ),
1161
- 'autoAttribute' => array (
1162
- 'id' => 'fancybox_autoAttributeYoutube',
1163
- 'input' => 'checkbox',
1164
- 'hide' => true,
1165
- 'default' => '1',
1166
- 'selector' => 'a[href*="youtu.be/"],area[href*="youtu.be/"],a[href*="youtube.com/watch"],area[href*="youtube.com/watch"]',
1167
- 'description' => __('Autodetect','easy-fancybox') . '<br />'
1168
- ),
1169
- 'tag' => array (
1170
- 'hide' => true,
1171
- 'default' => 'a.fancybox-youtube,area.fancybox-youtube,li.fancybox-youtube a'
1172
- ),
1173
- 'class' => array (
1174
- 'hide' => true,
1175
- 'default' => 'fancybox-youtube'
1176
- ),
1177
- 'type' => array(
1178
- 'default' => 'iframe'
1179
- ),
1180
- 'noCookie' => array (
1181
- 'id' => 'fancybox_YoutubenoCookie',
1182
- 'input' => 'checkbox',
1183
- 'hide' => true,
1184
- 'default' => '',
1185
- 'description' => __('Enable privacy-enhanced mode','easy-fancybox') . '<br />'
1186
- ),
1187
- 'width' => array (
1188
- 'id' => 'fancybox_YoutubeWidth',
1189
- 'title' => translate('Width'),
1190
- 'label_for' => 'fancybox_YoutubeWidth',
1191
- 'input' => 'number',
1192
- 'step' => '1',
1193
- 'min' => '420',
1194
- 'max' => '1500',
1195
- 'sanitize_callback' => 'intval',
1196
- 'class' => 'small-text',
1197
- 'default' => '640',
1198
- 'description' => ' '
1199
- ),
1200
- 'height' => array (
1201
- 'id' => 'fancybox_YoutubeHeight',
1202
- 'title' => translate('Height'),
1203
- 'label_for' => 'fancybox_YoutubeHeight',
1204
- 'input' => 'number',
1205
- 'step' => '1',
1206
- 'min' => '315',
1207
- 'max' => '900',
1208
- 'sanitize_callback' => 'intval',
1209
- 'class' => 'small-text',
1210
- 'default' => '360',
1211
- ),
1212
- 'padding' => array (
1213
- 'id' => 'fancybox_Youtubepadding',
1214
- 'title' => translate('Border'),
1215
- 'label_for' => 'fancybox_Youtubepadding',
1216
- 'input' => 'number',
1217
- 'step' => '1',
1218
- 'min' => '0',
1219
- 'max' => '100',
1220
- 'sanitize_callback' => 'intval',
1221
- 'class' => 'small-text',
1222
- 'default' => '0',
1223
- 'description' => '<br /><br />'
1224
- ),
1225
- 'keepRatio' => array(
1226
- 'noquotes' => true,
1227
- 'default' => '1'
1228
- ),
1229
- 'titleShow' => array (
1230
- 'id' => 'fancybox_YoutubetitleShow',
1231
- 'input' => 'checkbox',
1232
- 'noquotes' => true,
1233
- 'default' => '',
1234
- 'description' => __('Show title.','easy-fancybox') . ' ' . __('FancyBox will try to get a title from the link or thumbnail title attributes.','easy-fancybox')
1235
- ),
1236
- 'titlePosition' => array (
1237
- 'id' => 'fancybox_YoutubetitlePosition',
1238
- 'title' => __('Title Position','easy-fancybox'),
1239
- 'label_for' => 'fancybox_YoutubetitlePosition',
1240
- 'input' => 'select',
1241
- 'options' => array(
1242
- 'float' => __('Float','easy-fancybox'),
1243
- 'outside' => __('Outside','easy-fancybox'),
1244
- 'inside' => __('Inside','easy-fancybox')
1245
- ),
1246
- 'default' => 'float',
1247
- 'description' => '<br />'
1248
- ),
1249
- 'titleFromAlt' => array (
1250
- 'id' => 'fancybox_YoutubetitleFromAlt',
1251
- 'input' => 'checkbox',
1252
- 'noquotes' => true,
1253
- 'default' => '1',
1254
- 'description' => __('Allow title from thumbnail alt attribute.','easy-fancybox')
1255
- ),
1256
- 'onStart' => array (
1257
- 'noquotes' => true,
1258
- 'default' => get_option( 'fancybox_YoutubenoCookie' ) ?
1259
- 'function(a,i,o){o.href=a[i].href.replace(/https?:\/\/youtu\.be/gi,"https://www.youtube-nocookie.com/embed").replace(/https?:\/\/(?:www\.)?youtube\.com\/watch\?(.*)v=([a-z0-9\_\-]+)(?:&|&amp;|\?)?(.*)/gi,"https://www.youtube-nocookie.com/embed/$2?$1$3");var splitOn=o.href.indexOf("?");var urlParms=(splitOn>-1)?o.href.substring(splitOn):"";o.allowfullscreen=(urlParms.indexOf("fs=0")>-1)?false:true}' :
1260
- 'function(a,i,o){o.href=a[i].href.replace(/https?:\/\/youtu\.be/gi,"https://www.youtube.com/embed").replace(/https?:\/\/(?:www\.)?youtube\.com\/watch\?(.*)v=([a-z0-9\_\-]+)(?:&amp;|&|\?)?(.*)/gi,"https://www.youtube.com/embed/$2?$1$3");var splitOn=o.href.indexOf("?");var urlParms=(splitOn>-1)?o.href.substring(splitOn):"";o.allowfullscreen=(urlParms.indexOf("fs=0")>-1)?false:true}'
1261
- )
1262
- )
1263
- ),
1264
-
1265
- 'Vimeo' => array(
1266
- 'title' => __('Vimeo','easy-fancybox'),
1267
- 'input' => 'multiple',
1268
- 'options' => array(
1269
- 'intro' => array (
1270
- 'hide' => true,
1271
- 'description' => __('To make any Vimeo movie open in an overlay, switch on Autodetect or use the class "fancybox-vimeo" for its link.','easy-fancybox') . '<br />'
1272
- ),
1273
- 'autoAttribute' => array (
1274
- 'id' => 'fancybox_autoAttributeVimeo',
1275
- 'input' => 'checkbox',
1276
- 'hide' => true,
1277
- 'default' => '1',
1278
- 'selector' => 'a[href*="vimeo.com/"],area[href*="vimeo.com/"]',
1279
- 'description' => __('Autodetect','easy-fancybox') . '<br />'
1280
- ),
1281
- 'tag' => array (
1282
- 'hide' => true,
1283
- 'default' => 'a.fancybox-vimeo,area.fancybox-vimeo,li.fancybox-vimeo a'
1284
- ),
1285
- 'class' => array (
1286
- 'hide' => true,
1287
- 'default' => 'fancybox-vimeo'
1288
- ),
1289
- 'type' => array(
1290
- 'default' => 'iframe'
1291
- ),
1292
- 'width' => array (
1293
- 'id' => 'fancybox_VimeoWidth',
1294
- 'title' => translate('Width'),
1295
- 'label_for' => 'fancybox_VimeoWidth',
1296
- 'input' => 'number',
1297
- 'step' => '1',
1298
- 'min' => '400',
1299
- 'max' => '1500',
1300
- 'sanitize_callback' => 'intval',
1301
- 'class' => 'small-text',
1302
- 'default' => '500',
1303
- 'description' => ' '
1304
- ),
1305
- 'height' => array (
1306
- 'id' => 'fancybox_VimeoHeight',
1307
- 'title' => translate('Height'),
1308
- 'label_for' => 'fancybox_VimeoHeight',
1309
- 'input' => 'number',
1310
- 'step' => '1',
1311
- 'min' => '225',
1312
- 'max' => '900',
1313
- 'sanitize_callback' => 'intval',
1314
- 'class' => 'small-text',
1315
- 'default' => '281'
1316
- ),
1317
- 'padding' => array (
1318
- 'id' => 'fancybox_Vimeopadding',
1319
- 'title' => translate('Border'),
1320
- 'label_for' => 'fancybox_Vimeopadding',
1321
- 'input' => 'number',
1322
- 'step' => '1',
1323
- 'min' => '0',
1324
- 'max' => '100',
1325
- 'sanitize_callback' => 'intval',
1326
- 'class' => 'small-text',
1327
- 'default' => '0',
1328
- 'description' => '<br /><br />'
1329
- ),
1330
- 'keepRatio' => array(
1331
- 'noquotes' => true,
1332
- 'default' => '1'
1333
- ),
1334
- 'titleShow' => array (
1335
- 'id' => 'fancybox_VimeotitleShow',
1336
- 'input' => 'checkbox',
1337
- 'noquotes' => true,
1338
- 'default' => '',
1339
- 'description' => __('Show title.','easy-fancybox') . ' ' . __('FancyBox will try to get a title from the link or thumbnail title attributes.','easy-fancybox')
1340
- ),
1341
- 'titlePosition' => array (
1342
- 'id' => 'fancybox_VimeotitlePosition',
1343
- 'title' => __('Title Position','easy-fancybox'),
1344
- 'label_for' => 'fancybox_VimeotitlePosition',
1345
- 'input' => 'select',
1346
- 'options' => array(
1347
- 'float' => __('Float','easy-fancybox'),
1348
- 'outside' => __('Outside','easy-fancybox'),
1349
- 'inside' => __('Inside','easy-fancybox')
1350
- ),
1351
- 'default' => 'float',
1352
- 'description' => '<br />'
1353
- ),
1354
- 'titleFromAlt' => array (
1355
- 'id' => 'fancybox_VimeotitleFromAlt',
1356
- 'input' => 'checkbox',
1357
- 'noquotes' => true,
1358
- 'default' => '1',
1359
- 'description' => __('Allow title from thumbnail alt attribute.','easy-fancybox')
1360
- ),
1361
- 'onStart' => array (
1362
- 'noquotes' => true,
1363
- 'default' => 'function(a,i,o){o.href=a[i].href.replace(/https?:\/\/(?:www\.)?vimeo\.com\/([0-9]+)(?:&|&amp;|\?)?(.*)/gi,"https://player.vimeo.com/video/$1?$2");var splitOn=o.href.indexOf("?");var urlParms=(splitOn>-1)?o.href.substring(splitOn):"";o.allowfullscreen=(urlParms.indexOf("fullscreen=0")>-1)?false:true}'
1364
- )
1365
- )
1366
- ),
1367
-
1368
- 'Dailymotion' => array(
1369
- 'title' => __('Dailymotion','easy-fancybox'),
1370
- 'input' => 'multiple',
1371
- 'options' => array(
1372
- 'intro' => array (
1373
- 'hide' => true,
1374
- 'description' => __('To make any Dailymotion movie open in an overlay, switch on Autodetect or use the class "fancybox-dailymotion" for its link.','easy-fancybox') . '<br />'
1375
- ),
1376
- 'autoAttribute' => array (
1377
- 'id' => 'fancybox_autoAttributeDailymotion',
1378
- 'input' => 'checkbox',
1379
- 'hide' => true,
1380
- 'default' => '1',
1381
- 'selector' => 'a[href*="dailymotion.com/"],area[href*="dailymotion.com/"]',
1382
- 'description' => __('Autodetect','easy-fancybox') . '<br />'
1383
- ),
1384
- 'tag' => array (
1385
- 'hide' => true,
1386
- 'default' => 'a.fancybox-dailymotion,area.fancybox-dailymotion,li.fancybox-dailymotion a'
1387
- ),
1388
- 'class' => array (
1389
- 'hide' => true,
1390
- 'default' => 'fancybox-dailymotion'
1391
- ),
1392
- 'type' => array(
1393
- 'default' => 'iframe'
1394
- ),
1395
- 'width' => array (
1396
- 'id' => 'fancybox_DailymotionWidth',
1397
- 'title' => translate('Width'),
1398
- 'label_for' => 'fancybox_DailymotionWidth',
1399
- 'input' => 'number',
1400
- 'step' => '1',
1401
- 'min' => '320',
1402
- 'max' => '1500',
1403
- 'sanitize_callback' => 'intval',
1404
- 'class' => 'small-text',
1405
- 'default' => '560',
1406
- 'description' => ' '
1407
- ),
1408
- 'height' => array (
1409
- 'id' => 'fancybox_DailymotionHeight',
1410
- 'title' => translate('Height'),
1411
- 'label_for' => 'fancybox_DailymotionHeight',
1412
- 'input' => 'number',
1413
- 'step' => '1',
1414
- 'min' => '180',
1415
- 'max' => '900',
1416
- 'sanitize_callback' => 'intval',
1417
- 'class' => 'small-text',
1418
- 'default' => '315'
1419
- ),
1420
- 'padding' => array (
1421
- 'id' => 'fancybox_DailymotionPadding',
1422
- 'title' => translate('Border'),
1423
- 'label_for' => 'fancybox_DailymotionPadding',
1424
- 'input' => 'number',
1425
- 'step' => '1',
1426
- 'min' => '0',
1427
- 'max' => '100',
1428
- 'sanitize_callback' => 'intval',
1429
- 'class' => 'small-text',
1430
- 'default' => '0',
1431
- 'description' => '<br /><br />'
1432
- ),
1433
- 'keepRatio' => array(
1434
- 'noquotes' => true,
1435
- 'default' => '1'
1436
- ),
1437
- 'titleShow' => array (
1438
- 'id' => 'fancybox_DailymotiontitleShow',
1439
- 'input' => 'checkbox',
1440
- 'noquotes' => true,
1441
- 'default' => '',
1442
- 'description' => __('Show title.','easy-fancybox') . ' ' . __('FancyBox will try to get a title from the link or thumbnail title attributes.','easy-fancybox')
1443
- ),
1444
- 'titlePosition' => array (
1445
- 'id' => 'fancybox_DailymotiontitlePosition',
1446
- 'title' => __('Title Position','easy-fancybox'),
1447
- 'label_for' => 'fancybox_DailymotiontitlePosition',
1448
- 'input' => 'select',
1449
- 'options' => array(
1450
- 'float' => __('Float','easy-fancybox'),
1451
- 'outside' => __('Outside','easy-fancybox'),
1452
- 'inside' => __('Inside','easy-fancybox')
1453
- ),
1454
- 'default' => 'float',
1455
- 'description' => '<br />'
1456
- ),
1457
- 'titleFromAlt' => array (
1458
- 'id' => 'fancybox_DailymotiontitleFromAlt',
1459
- 'input' => 'checkbox',
1460
- 'noquotes' => true,
1461
- 'default' => '1',
1462
- 'description' => __('Allow title from thumbnail alt attribute.','easy-fancybox')
1463
- ),
1464
- 'onStart' => array (
1465
- 'noquotes' => true,
1466
- 'default' => 'function(a,i,o){o.href=a[i].href.replace(/^https?:\/\/(?:www\.)dailymotion.com\/video\/(.*)/gi,"https://www.dailymotion.com/embed/video/$1");var splitOn=o.href.indexOf("?");var urlParms=(splitOn>-1)?o.href.substring(splitOn):"";o.allowfullscreen=(urlParms.indexOf("fullscreen=0")>-1)?false:true}'
1467
- )
1468
- )
1469
- ),
1470
-
1471
- /* 'Tudou' => array(
1472
- 'id' => 'fancybox_Tudou',
1473
- 'title' => __('Tudou','easy-fancybox'),
1474
- 'label_for' => '',
1475
- 'input' => 'multiple',
1476
- 'class' => '', 'description' => '',
1477
- 'options' => array(
1478
- 'autoAttributeTudou' => array (
1479
- 'id' => 'fancybox_autoAttributeTudou',
1480
- 'label_for' => '',
1481
- 'input' => 'checkbox',
1482
- 'class' => '',
1483
- 'options' => array(),
1484
- 'hide' => true,
1485
- 'default' => '1',
1486
- 'description' => __('Tudou links','easy-fancybox')
1487
- )
1488
- )
1489
- ),*/
1490
-
1491
- /* 'Animoto' => array(),
1492
-
1493
- Example ANIMOTO page link http://animoto.com/play/Kf9POzQMSOGWyu41gtOtsw should become
1494
- http://static.animoto.com/swf/w.swf?w=swf/vp1&f=Kf9POzQMSOGWyu41gtOtsw&i=m
1495
-
1496
- */
1497
-
1498
- 'iFrame' => array(
1499
- 'title' => __('iFrames','easy-fancybox'),
1500
- 'input' => 'multiple',
1501
- 'options' => array(
1502
- 'intro' => array (
1503
- 'hide' => true,
1504
- 'description' => __('To make a website or HTML document open in an overlay, use the class "fancybox-iframe" for its link.','easy-fancybox') . '<br /><br />'
1505
- ),
1506
- 'tag' => array (
1507
- 'hide' => true,
1508
- 'default' => 'a.fancybox-iframe,area.fancybox-iframe,li.fancybox-iframe a'
1509
- ),
1510
- 'class' => array (
1511
- 'hide' => true,
1512
- 'default' => 'fancybox-iframe'
1513
- ),
1514
- 'type' => array (
1515
- 'default' => 'iframe'
1516
- ),
1517
- /*
1518
- * other than overflow:auto not supported on many browsers
1519
- 'scrolling' => array (
1520
- 'id' => 'fancybox_iFrameScrolling',
1521
- 'title' => __('Scrolling','easy-fancybox'),
1522
- 'label_for' => 'fancybox_iFrameScrolling',
1523
- 'input' => 'select',
1524
- 'options' => array(
1525
- 'auto' => __('Auto','easy-fancybox'),
1526
- 'yes' => __('Always','easy-fancybox'),
1527
- 'no' => __('Never','easy-fancybox')
1528
- ),
1529
- 'default' => 'auto',
1530
- 'description' => __('Define scrolling and scrollbar visibility.','easy-fancybox') . '<br />'
1531
- ),
1532
- */
1533
- 'width' => array (
1534
- 'id' => 'fancybox_iFramewidth',
1535
- 'title' => translate('Width'),
1536
- 'label_for' => 'fancybox_iFramewidth',
1537
- 'input' => 'text',
1538
- 'sanitize_callback' => 'intval',
1539
- 'class' => 'small-text',
1540
- 'default' => '70%',
1541
- 'description' => ' '
1542
- ),
1543
- 'height' => array (
1544
- 'id' => 'fancybox_iFrameheight',
1545
- 'title' => translate('Height'),
1546
- 'label_for' => 'fancybox_iFrameheight',
1547
- 'input' => 'text',
1548
- 'sanitize_callback' => 'intval',
1549
- 'class' => 'small-text',
1550
- 'default' => '90%',
1551
- ),
1552
- 'padding' => array (
1553
- 'id' => 'fancybox_iFramepadding',
1554
- 'title' => translate('Border'),
1555
- 'label_for' => 'fancybox_iFramepadding',
1556
- 'input' => 'number',
1557
- 'step' => '1',
1558
- 'min' => '0',
1559
- 'max' => '100',
1560
- 'sanitize_callback' => 'intval',
1561
- 'class' => 'small-text',
1562
- 'default' => '0',
1563
- 'description' => '<br /><br />'
1564
- ),
1565
- 'titleShow' => array (
1566
- 'id' => 'fancybox_iFrametitleShow',
1567
- 'input' => 'checkbox',
1568
- 'noquotes' => true,
1569
- 'default' => '',
1570
- 'description' => __('Show title.','easy-fancybox') . ' ' . __('FancyBox will try to get a title from the link or thumbnail title attributes.','easy-fancybox')
1571
- ),
1572
- 'titlePosition' => array (
1573
- 'id' => 'fancybox_iFrametitlePosition',
1574
- 'title' => __('Title Position','easy-fancybox'),
1575
- 'label_for' => 'fancybox_iFrametitlePosition',
1576
- 'input' => 'select',
1577
- 'options' => array(
1578
- 'float' => __('Float','easy-fancybox'),
1579
- 'outside' => __('Outside','easy-fancybox'),
1580
- 'inside' => __('Inside','easy-fancybox')
1581
- ),
1582
- 'default' => 'float',
1583
- 'description' => '<br />'
1584
- ),
1585
- 'titleFromAlt' => array (
1586
- 'id' => 'fancybox_iFrametitleFromAlt',
1587
- 'input' => 'checkbox',
1588
- 'noquotes' => true,
1589
- 'default' => '1',
1590
- 'description' => __('Allow title from thumbnail alt attribute.','easy-fancybox') . '<br/>'
1591
- ),
1592
- 'allowfullscreen' => array (
1593
- 'id' => 'fancybox_allowFullScreen',
1594
- 'input' => 'checkbox',
1595
- 'noquotes' => true,
1596
- 'default' => '',
1597
- 'description' => __('Allow embedded content to jump to full screen mode','easy-fancybox')
1598
- )
1599
- )
1600
- )
1601
- );
1602
- }
1603
- }