Easy FancyBox - Version 1.7

Version Description

Fix: pre PHP5.4 compatibility. Switch to wp_add_inline_script() script printing.

=

Download this release

Release Info

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

Code changes from version 1.6.3 to 1.7

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