File manager - Edit - /home/asiatechinc/public_html/asiatech-websites/citadelresortpanchgani.com/js/jquery.main.js
Back
function scrollNav(){"use strict";jQuery(".go-top").click(function(){return jQuery("html, body").stop().animate({scrollTop:jQuery(jQuery(this).attr("href")).offset().top-160},400),!1})}function initMobileNav(){"use strict";jQuery("body").mobileNav({hideOnClickOutside:!0,menuActiveClass:"active",menuOpener:".navbar-toggle",menuDrop:".navbar-collapse"})}function initFitVids(){"use strict";jQuery(".video").fitVids()}scrollNav(),jQuery(function(){"use strict";var e=new Date,t=new Date(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0,0),i=jQuery("#dpd1").datepicker({onRender:function(e){return e.valueOf()<t.valueOf()?"disabled":""}}).on("changeDate",function(e){if(e.date.valueOf()>n.date.valueOf()){var t=new Date(e.date);t.setDate(t.getDate()+1),n.setValue(t)}i.hide(),jQuery("#dpd2")[0].focus()}).data("datepicker"),n=jQuery("#dpd2").datepicker({onRender:function(e){return e.valueOf()<=i.date.valueOf()?"disabled":""}}).on("changeDate",function(e){n.hide()}).data("datepicker")}),jQuery(function(){"use strict";jQuery(".stats").counter({autoStart:!1}),jQuery(".horizon").horizon({recurring:!0,inView:function(){jQuery(".stats").each(function(){jQuery(this).data("counter").startCounter()})},outOfView:function(){jQuery(".stats").each(function(){jQuery(this).data("counter").clearCounter()})}})}),jQuery(function(){"use strict";var e=new Date;e=new Date(e.getFullYear()+1,-5,9),jQuery("#defaultCountdown").countdown({until:e}),jQuery("#year").text(e.getFullYear())}),jQuery(function(){"use strict";initMobileNav(),initFitVids(),jQuery("input, textarea").placeholder()}),function(e){function t(t){this.options=e.extend({container:null,hideOnClickOutside:!1,menuActiveClass:"nav-active",menuOpener:".nav-opener",menuDrop:".nav-drop",toggleEvent:"click",outsideClickEvent:"click touchstart pointerdown MSPointerDown"},t),this.initStructure(),this.attachEvents()}t.prototype={initStructure:function(){this.page=e("html"),this.container=e(this.options.container),this.opener=this.container.find(this.options.menuOpener),this.drop=this.container.find(this.options.menuDrop)},attachEvents:function(){var t=this;i&&(i(),i=null),this.outsideClickHandler=function(i){if(t.isOpened()){var n=e(i.target);n.closest(t.opener).length||n.closest(t.drop).length||t.hide()}},this.openerClickHandler=function(e){e.preventDefault(),t.toggle()},this.opener.on(this.options.toggleEvent,this.openerClickHandler)},isOpened:function(){return this.container.hasClass(this.options.menuActiveClass)},show:function(){this.container.addClass(this.options.menuActiveClass),this.options.hideOnClickOutside&&this.page.on(this.options.outsideClickEvent,this.outsideClickHandler)},hide:function(){this.container.removeClass(this.options.menuActiveClass),this.options.hideOnClickOutside&&this.page.off(this.options.outsideClickEvent,this.outsideClickHandler)},toggle:function(){this.isOpened()?this.hide():this.show()},destroy:function(){this.container.removeClass(this.options.menuActiveClass),this.opener.off(this.options.toggleEvent,this.clickHandler),this.page.off(this.options.outsideClickEvent,this.outsideClickHandler)}};var i=function(){var t,i,n=e(window),o=e("html"),a="resize-active",r=function(){t=!1,o.removeClass(a)},s=function(){t||(t=!0,o.addClass(a)),clearTimeout(i),i=setTimeout(r,500)};n.on("resize orientationchange",s)};e.fn.mobileNav=function(i){return this.each(function(){var n=e.extend({},i,{container:this}),o=new t(n);e.data(this,"MobileNav",o)})}}(jQuery),function(e){e.fn.sameHeight=function(o){var a=e.extend({skipClass:"same-height-ignore",leftEdgeClass:"same-height-left",rightEdgeClass:"same-height-right",elements:">*",flexible:!1,multiLine:!1,useMinHeight:!1,biggestHeight:!1},o);return this.each(function(){var o,r,s=e(this),l=s.find(a.elements).not("."+a.skipClass);if(l.length){d();var c=function(){r||(r=!0,d(),clearTimeout(o),o=setTimeout(function(){d(),setTimeout(function(){r=!1},10)},100))};a.flexible&&e(window).bind("resize orientationchange fontresize",c),e(window).bind("load",c)}function d(){var o,r,c,d,h,p;l.css(a.useMinHeight&&t?"minHeight":"height",""),a.multiLine?(o=l,r=a,d=e(),h=0,p=o.eq(0).offset().top,o.each(function(t){var o=e(this);o.offset().top===p?d=d.add(this):(c=i(d),h=Math.max(h,n(d,c,r)),d=o,p=o.offset().top)}),d.length&&(c=i(d),h=Math.max(h,n(d,c,r))),r.biggestHeight&&o.css(r.useMinHeight&&t?"minHeight":"height",h)):n(l,s,a)}})};var t=void 0!==document.documentElement.style.maxHeight;function i(t){var i=0;return t.each(function(){i=Math.max(i,e(this).outerHeight())}),i}function n(i,n,o){var a,r="number"==typeof n?n:n.height();return i.removeClass(o.leftEdgeClass).removeClass(o.rightEdgeClass).each(function(i){var s=e(this),l=0,c="border-box"===s.css("boxSizing")||"border-box"===s.css("-moz-box-sizing");"number"!=typeof n&&s.parents().each(function(){var t=e(this);if(n.is(this))return!1;l+=t.outerHeight()-t.height()}),a=r-l,(a-=c?0:s.outerHeight()-s.height())>0&&s.css(o.useMinHeight&&t?"minHeight":"height",a)}),i.filter(":first").addClass(o.leftEdgeClass),i.filter(":last").addClass(o.rightEdgeClass),a}}(jQuery),function(e,t,i){var n,o,a="[object OperaMini]"==Object.prototype.toString.call(e.operamini),r="placeholder"in t.createElement("input")&&!a,s="placeholder"in t.createElement("textarea")&&!a,l=i.fn,c=i.valHooks,d=i.propHooks;function h(e,t){var n=this,o=i(n);if(n.value==o.attr("placeholder")&&o.hasClass("placeholder")){if(o.data("placeholder-password")){if(o=o.hide().next().show().attr("id",o.removeAttr("id").data("placeholder-id")),!0===e)return o[0].value=t;o.focus()}else n.value="",o.removeClass("placeholder"),n==u()&&n.select()}}function p(){var e,t,n,o,a=i(this),r=this.id;if(""==this.value){if("password"==this.type){if(!a.data("placeholder-textinput")){try{o=a.clone().attr({type:"text"})}catch(s){o=i("<input>").attr(i.extend((e=this,t={},n=/^jQuery\d+$/,i.each(e.attributes,function(e,i){i.specified&&!n.test(i.name)&&(t[i.name]=i.value)}),t),{type:"text"}))}o.removeAttr("name").data({"placeholder-password":a,"placeholder-id":r}).bind("focus.placeholder",h),a.data({"placeholder-textinput":o,"placeholder-id":r}).before(o)}a=a.removeAttr("id").hide().prev().attr("id",r).show()}a.addClass("placeholder"),a[0].value=a.attr("placeholder")}else a.removeClass("placeholder")}function u(){try{return t.activeElement}catch(e){}}r&&s?(o=l.placeholder=function(){return this}).input=o.textarea=!0:((o=l.placeholder=function(){return this.filter((r?"textarea":":input")+"[placeholder]").not(".placeholder").bind({"focus.placeholder":h,"blur.placeholder":p}).data("placeholder-enabled",!0).trigger("blur.placeholder"),this}).input=r,o.textarea=s,n={get:function(e){var t=i(e),n=t.data("placeholder-password");return n?n[0].value:t.data("placeholder-enabled")&&t.hasClass("placeholder")?"":e.value},set:function(e,t){var n=i(e),o=n.data("placeholder-password");return o?o[0].value=t:n.data("placeholder-enabled")?(""==t?(e.value=t,e!=u()&&p.call(e)):n.hasClass("placeholder")&&h.call(e,!0,t)||(e.value=t),n):e.value=t}},r||(c.input=n,d.value=n),s||(c.textarea=n,d.value=n),i(function(){i(t).delegate("form","submit.placeholder",function(){var e=i(".placeholder",this).each(h);setTimeout(function(){e.each(p)},10)})}),i(e).bind("beforeunload.placeholder",function(){i(".placeholder").each(function(){this.value=""})}))}(this,document,jQuery),/*! fancyBox v2.1.5 fancyapps.com | fancyapps.com/fancybox/#license */ function(e,t,i,n){var o=i("html"),a=i(e),r=i(t),s=i.fancybox=function(){s.open.apply(this,arguments)},l=navigator.userAgent.match(/msie/i),c=null,d=t.createTouch!==n,h=function(e){return e&&e.hasOwnProperty&&e instanceof i},p=function(e){return e&&"string"===i.type(e)},u=function(e){return p(e)&&0<e.indexOf("%")},f=function(e,t){var i=parseInt(e,10)||0;return t&&u(e)&&(i*=s.getViewport()[t]/100),Math.ceil(i)},g=function(e,t){return f(e,t)+"px"};i.extend(s,{version:"2.1.5",defaults:{padding:0,margin:20,width:800,height:600,minWidth:100,minHeight:100,maxWidth:9999,maxHeight:9999,pixelRatio:1,autoSize:!0,autoHeight:!1,autoWidth:!1,autoResize:!0,autoCenter:!d,fitToView:!0,aspectRatio:!1,topRatio:.5,leftRatio:.5,scrolling:"auto",wrapCSS:"",arrows:!0,closeBtn:!0,closeClick:!1,nextClick:!1,mouseWheel:!0,autoPlay:!1,playSpeed:3e3,preload:3,modal:!1,loop:!0,ajax:{dataType:"html",headers:{"X-fancyBox":!0}},iframe:{scrolling:"auto",preload:!0},swf:{wmode:"transparent",allowfullscreen:"true",allowscriptaccess:"always"},keys:{next:{13:"left",34:"up",39:"left",40:"up"},prev:{8:"right",33:"down",37:"right",38:"down"},close:[27],play:[32],toggle:[70]},direction:{next:"left",prev:"right"},scrollOutside:!0,index:0,type:null,href:null,content:null,title:null,tpl:{wrap:'<div class="fancybox-wrap" tabIndex="-1"><div class="fancybox-skin"><div class="fancybox-outer"><div class="fancybox-inner"></div></div></div></div>',image:'<img class="fancybox-image" src="{href}" alt="" />',iframe:'<iframe id="fancybox-frame{rnd}" name="fancybox-frame{rnd}" class="fancybox-iframe" frameborder="0" vspace="0" hspace="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen'+(l?' allowtransparency="true"':"")+"></iframe>",error:'<p class="fancybox-error">The requested content cannot be loaded.<br/>Please try again later.</p>',closeBtn:'<a title="Close" class="fancybox-item fancybox-close" href="javascript:;"></a>',next:'<a title="Next" class="fancybox-nav fancybox-next" href="javascript:;"><span></span></a>',prev:'<a title="Previous" class="fancybox-nav fancybox-prev" href="javascript:;"><span></span></a>'},openEffect:"fade",openSpeed:250,openEasing:"swing",openOpacity:!0,openMethod:"zoomIn",closeEffect:"fade",closeSpeed:250,closeEasing:"swing",closeOpacity:!0,closeMethod:"zoomOut",nextEffect:"elastic",nextSpeed:250,nextEasing:"swing",nextMethod:"changeIn",prevEffect:"elastic",prevSpeed:250,prevEasing:"swing",prevMethod:"changeOut",helpers:{overlay:!0,title:!0},onCancel:i.noop,beforeLoad:i.noop,afterLoad:i.noop,beforeShow:i.noop,afterShow:i.noop,beforeChange:i.noop,beforeClose:i.noop,afterClose:i.noop},group:{},opts:{},previous:null,coming:null,current:null,isActive:!1,isOpen:!1,isOpened:!1,wrap:null,skin:null,outer:null,inner:null,player:{timer:null,isActive:!1},ajaxLoad:null,imgPreload:null,transitions:{},helpers:{},open:function(e,t){if(e&&(i.isPlainObject(t)||(t={}),!1!==s.close(!0)))return i.isArray(e)||(e=h(e)?i(e).get():[e]),i.each(e,function(o,a){var r,l,c,d,u,f={};"object"===i.type(a)&&(a.nodeType&&(a=i(a)),h(a)?(f={href:a.data("fancybox-href")||a.attr("href"),title:a.data("fancybox-title")||a.attr("title"),isDom:!0,element:a},i.metadata&&i.extend(!0,f,a.metadata())):f=a),r=t.href||f.href||(p(a)?a:null),l=t.title!==n?t.title:f.title||"",!(d=(c=t.content||f.content)?"html":t.type||f.type)&&f.isDom&&((d=a.data("fancybox-type"))||(d=(d=a.prop("class").match(/fancybox\.(\w+)/))?d[1]:null)),p(r)&&(d||(s.isImage(r)?d="image":s.isSWF(r)?d="swf":"#"===r.charAt(0)?d="inline":p(a)&&(d="html",c=a)),"ajax"===d&&(r=(u=r.split(/\s+/,2)).shift(),u=u.shift())),c||("inline"===d?r?c=i(p(r)?r.replace(/.*(?=#[^\s]+$)/,""):r):f.isDom&&(c=a):"html"===d?c=r:d||r||!f.isDom||(d="inline",c=a)),i.extend(f,{href:r,type:d,content:c,title:l,selector:u}),e[o]=f}),s.opts=i.extend(!0,{},s.defaults,t),t.keys!==n&&(s.opts.keys=!!t.keys&&i.extend({},s.defaults.keys,t.keys)),s.group=e,s._start(s.opts.index)},cancel:function(){var e=s.coming;e&&!1!==s.trigger("onCancel")&&(s.hideLoading(),s.ajaxLoad&&s.ajaxLoad.abort(),s.ajaxLoad=null,s.imgPreload&&(s.imgPreload.onload=s.imgPreload.onerror=null),e.wrap&&e.wrap.stop(!0,!0).trigger("onReset").remove(),s.coming=null,s.current||s._afterZoomOut(e))},close:function(e){s.cancel(),!1!==s.trigger("beforeClose")&&(s.unbindEvents(),s.isActive&&(s.isOpen&&!0!==e?(s.isOpen=s.isOpened=!1,s.isClosing=!0,i(".fancybox-item, .fancybox-nav").remove(),s.wrap.stop(!0,!0).removeClass("fancybox-opened"),s.transitions[s.current.closeMethod]()):(i(".fancybox-wrap").stop(!0).trigger("onReset").remove(),s._afterZoomOut())))},play:function(e){var t=function(){clearTimeout(s.player.timer)},i=function(){t(),s.current&&s.player.isActive&&(s.player.timer=setTimeout(s.next,s.current.playSpeed))},n=function(){t(),r.unbind(".player"),s.player.isActive=!1,s.trigger("onPlayEnd")};!0!==e&&(s.player.isActive||!1===e)?n():s.current&&(s.current.loop||s.current.index<s.group.length-1)&&(s.player.isActive=!0,r.bind({"onCancel.player beforeClose.player":n,"onUpdate.player":i,"beforeLoad.player":t}),i(),s.trigger("onPlayStart"))},next:function(e){var t=s.current;t&&(p(e)||(e=t.direction.next),s.jumpto(t.index+1,e,"next"))},prev:function(e){var t=s.current;t&&(p(e)||(e=t.direction.prev),s.jumpto(t.index-1,e,"prev"))},jumpto:function(e,t,i){var o=s.current;o&&(e=f(e),s.direction=t||o.direction[e>=o.index?"next":"prev"],s.router=i||"jumpto",o.loop&&(0>e&&(e=o.group.length+e%o.group.length),e%=o.group.length),o.group[e]!==n&&(s.cancel(),s._start(e)))},reposition:function(e,t){var n,o=s.current,a=o?o.wrap:null;a&&(n=s._getPosition(t),e&&"scroll"===e.type?(delete n.position,a.stop(!0,!0).animate(n,200)):(a.css(n),o.pos=i.extend({},o.dim,n)))},update:function(e){var t=e&&e.type,i=!t||"orientationchange"===t;i&&(clearTimeout(c),c=null),s.isOpen&&!c&&(c=setTimeout(function(){var n=s.current;n&&!s.isClosing&&(s.wrap.removeClass("fancybox-tmp"),(i||"load"===t||"resize"===t&&n.autoResize)&&s._setDimension(),"scroll"===t&&n.canShrink||s.reposition(e),s.trigger("onUpdate"),c=null)},i&&!d?0:300))},toggle:function(e){s.isOpen&&(s.current.fitToView="boolean"===i.type(e)?e:!s.current.fitToView,d&&(s.wrap.removeAttr("style").addClass("fancybox-tmp"),s.trigger("onUpdate")),s.update())},hideLoading:function(){r.unbind(".loading"),i("#fancybox-loading").remove()},showLoading:function(){var e,t;s.hideLoading(),e=i('<div id="fancybox-loading"><div></div></div>').click(s.cancel).appendTo("body"),r.bind("keydown.loading",function(e){27===(e.which||e.keyCode)&&(e.preventDefault(),s.cancel())}),s.defaults.fixed||(t=s.getViewport(),e.css({position:"absolute",top:.5*t.h+t.y,left:.5*t.w+t.x}))},getViewport:function(){var t=s.current&&s.current.locked||!1,i={x:a.scrollLeft(),y:a.scrollTop()};return t?(i.w=t[0].clientWidth,i.h=t[0].clientHeight):(i.w=d&&e.innerWidth?e.innerWidth:a.width(),i.h=d&&e.innerHeight?e.innerHeight:a.height()),i},unbindEvents:function(){s.wrap&&h(s.wrap)&&s.wrap.unbind(".fb"),r.unbind(".fb"),a.unbind(".fb")},bindEvents:function(){var e,t=s.current;t&&(a.bind("orientationchange.fb"+(d?"":" resize.fb")+(t.autoCenter&&!t.locked?" scroll.fb":""),s.update),(e=t.keys)&&r.bind("keydown.fb",function(o){var a=o.which||o.keyCode,r=o.target||o.srcElement;if(27===a&&s.coming)return!1;o.ctrlKey||o.altKey||o.shiftKey||o.metaKey||r&&(r.type||i(r).is("[contenteditable]"))||i.each(e,function(e,r){return 1<t.group.length&&r[a]!==n?(s[e](r[a]),o.preventDefault(),!1):-1<i.inArray(a,r)?(s[e](),o.preventDefault(),!1):void 0})}),i.fn.mousewheel&&t.mouseWheel&&s.wrap.bind("mousewheel.fb",function(e,n,o,a){for(var r=i(e.target||null),l=!1;r.length&&!l&&!r.is(".fancybox-skin")&&!r.is(".fancybox-wrap");)l=r[0]&&!(r[0].style.overflow&&"hidden"===r[0].style.overflow)&&(r[0].clientWidth&&r[0].scrollWidth>r[0].clientWidth||r[0].clientHeight&&r[0].scrollHeight>r[0].clientHeight),r=i(r).parent();0===n||l||!(1<s.group.length)||t.canShrink||(0<a||0<o?s.prev(0<a?"down":"left"):(0>a||0>o)&&s.next(0>a?"up":"right"),e.preventDefault())}))},trigger:function(e,t){var n,o=t||s.coming||s.current;if(o){if(i.isFunction(o[e])&&(n=o[e].apply(o,Array.prototype.slice.call(arguments,1))),!1===n)return!1;o.helpers&&i.each(o.helpers,function(t,n){n&&s.helpers[t]&&i.isFunction(s.helpers[t][e])&&s.helpers[t][e](i.extend(!0,{},s.helpers[t].defaults,n),o)}),r.trigger(e)}},isImage:function(e){return p(e)&&e.match(/(^data:image\/.*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg)((\?|#).*)?$)/i)},isSWF:function(e){return p(e)&&e.match(/\.(swf)((\?|#).*)?$/i)},_start:function(e){var t,n,o={};if(e=f(e),!(t=s.group[e]||null))return!1;if(t=(o=i.extend(!0,{},s.opts,t)).margin,n=o.padding,"number"===i.type(t)&&(o.margin=[t,t,t,t]),"number"===i.type(n)&&(o.padding=[n,n,n,n]),o.modal&&i.extend(!0,o,{closeBtn:!1,closeClick:!1,nextClick:!1,arrows:!1,mouseWheel:!1,keys:null,helpers:{overlay:{closeClick:!1}}}),o.autoSize&&(o.autoWidth=o.autoHeight=!0),"auto"===o.width&&(o.autoWidth=!0),"auto"===o.height&&(o.autoHeight=!0),o.group=s.group,o.index=e,s.coming=o,!1===s.trigger("beforeLoad"))s.coming=null;else{if(n=o.type,t=o.href,!n)return s.coming=null,!!s.current&&!!s.router&&"jumpto"!==s.router&&(s.current.index=e,s[s.router](s.direction));if(s.isActive=!0,("image"===n||"swf"===n)&&(o.autoHeight=o.autoWidth=!1,o.scrolling="visible"),"image"===n&&(o.aspectRatio=!0),"iframe"===n&&d&&(o.scrolling="scroll"),o.wrap=i(o.tpl.wrap).addClass("fancybox-"+(d?"mobile":"desktop")+" fancybox-type-"+n+" fancybox-tmp "+o.wrapCSS).appendTo(o.parent||"body"),i.extend(o,{skin:i(".fancybox-skin",o.wrap),outer:i(".fancybox-outer",o.wrap),inner:i(".fancybox-inner",o.wrap)}),i.each(["Top","Right","Bottom","Left"],function(e,t){o.skin.css("padding"+t,g(o.padding[e]))}),s.trigger("onReady"),"inline"===n||"html"===n){if(!o.content||!o.content.length)return s._error("content")}else if(!t)return s._error("href");"image"===n?s._loadImage():"ajax"===n?s._loadAjax():"iframe"===n?s._loadIframe():s._afterLoad()}},_error:function(e){i.extend(s.coming,{type:"html",autoWidth:!0,autoHeight:!0,minWidth:0,minHeight:0,scrolling:"no",hasError:e,content:s.coming.tpl.error}),s._afterLoad()},_loadImage:function(){var e=s.imgPreload=new Image;e.onload=function(){this.onload=this.onerror=null,s.coming.width=this.width/s.opts.pixelRatio,s.coming.height=this.height/s.opts.pixelRatio,s._afterLoad()},e.onerror=function(){this.onload=this.onerror=null,s._error("image")},e.src=s.coming.href,!0!==e.complete&&s.showLoading()},_loadAjax:function(){var e=s.coming;s.showLoading(),s.ajaxLoad=i.ajax(i.extend({},e.ajax,{url:e.href,error:function(e,t){s.coming&&"abort"!==t?s._error("ajax",e):s.hideLoading()},success:function(t,i){"success"===i&&(e.content=t,s._afterLoad())}}))},_loadIframe:function(){var e=s.coming,t=i(e.tpl.iframe.replace(/\{rnd\}/g,(new Date).getTime())).attr("scrolling",d?"auto":e.iframe.scrolling).attr("src",e.href);i(e.wrap).bind("onReset",function(){try{i(this).find("iframe").hide().attr("src","//about:blank").end().empty()}catch(e){}}),e.iframe.preload&&(s.showLoading(),t.one("load",function(){i(this).data("ready",1),d||i(this).bind("load.fb",s.update),i(this).parents(".fancybox-wrap").width("100%").removeClass("fancybox-tmp").show(),s._afterLoad()})),e.content=t.appendTo(e.inner),e.iframe.preload||s._afterLoad()},_preloadImages:function(){var e,t,i=s.group,n=s.current,o=i.length,a=n.preload?Math.min(n.preload,o-1):0;for(t=1;t<=a;t+=1)"image"===(e=i[(n.index+t)%o]).type&&e.href&&((new Image).src=e.href)},_afterLoad:function(){var e,t,n,o,a,r=s.coming,l=s.current;if(s.hideLoading(),r&&!1!==s.isActive){if(!1===s.trigger("afterLoad",r,l))r.wrap.stop(!0).trigger("onReset").remove(),s.coming=null;else{switch(l&&(s.trigger("beforeChange",l),l.wrap.stop(!0).removeClass("fancybox-opened").find(".fancybox-item, .fancybox-nav").remove()),s.unbindEvents(),e=r.content,t=r.type,n=r.scrolling,i.extend(s,{wrap:r.wrap,skin:r.skin,outer:r.outer,inner:r.inner,current:r,previous:l}),o=r.href,t){case"inline":case"ajax":case"html":r.selector?e=i("<div>").html(e).find(r.selector):h(e)&&(e.data("fancybox-placeholder")||e.data("fancybox-placeholder",i('<div class="fancybox-placeholder"></div>').insertAfter(e).hide()),e=e.show().detach(),r.wrap.bind("onReset",function(){i(this).find(e).length&&e.hide().replaceAll(e.data("fancybox-placeholder")).data("fancybox-placeholder",!1)}));break;case"image":e=r.tpl.image.replace("{href}",o);break;case"swf":e='<object id="fancybox-swf" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="100%" height="100%"><param name="movie" value="'+o+'"></param>',a="",i.each(r.swf,function(t,i){e+='<param name="'+t+'" value="'+i+'"></param>',a+=" "+t+'="'+i+'"'}),e+='<embed src="'+o+'" type="application/x-shockwave-flash" width="100%" height="100%"'+a+"></embed></object>"}h(e)&&e.parent().is(r.inner)||r.inner.append(e),s.trigger("beforeShow"),r.inner.css("overflow","yes"===n?"scroll":"no"===n?"hidden":n),s._setDimension(),s.reposition(),s.isOpen=!1,s.coming=null,s.bindEvents(),s.isOpened?l.prevMethod&&s.transitions[l.prevMethod]():i(".fancybox-wrap").not(r.wrap).stop(!0).trigger("onReset").remove(),s.transitions[s.isOpened?r.nextMethod:r.openMethod](),s._preloadImages()}}},_setDimension:function(){var e,t,n,o,a,r,l,c,d,h=s.getViewport(),p=0,m=!1,v=!1,m=s.wrap,y=s.skin,x=s.inner,b=s.current,v=b.width,w=b.height,_=b.minWidth,C=b.minHeight,k=b.maxWidth,O=b.maxHeight,E=b.scrolling,H=b.scrollOutside?b.scrollbarWidth:0,S=b.margin,W=f(S[1]+S[3]),L=f(S[0]+S[2]);if(m.add(y).add(x).width("auto").height("auto").removeClass("fancybox-tmp"),S=f(y.outerWidth(!0)-y.width()),e=f(y.outerHeight(!0)-y.height()),t=W+S,n=L+e,o=u(v)?(h.w-t)*f(v)/100:v,a=u(w)?(h.h-n)*f(w)/100:w,"iframe"===b.type){if(d=b.content,b.autoHeight&&1===d.data("ready"))try{d[0].contentWindow.document.location&&(x.width(o).height(9999),r=d.contents().find("body"),H&&r.css("overflow-x","hidden"),a=r.outerHeight(!0))}catch(A){}}else(b.autoWidth||b.autoHeight)&&(x.addClass("fancybox-tmp"),b.autoWidth||x.width(o),b.autoHeight||x.height(a),b.autoWidth&&(o=x.width()),b.autoHeight&&(a=x.height()),x.removeClass("fancybox-tmp"));if(v=f(o),w=f(a),c=o/a,_=f(u(_)?f(_,"w")-t:_),k=f(u(k)?f(k,"w")-t:k),C=f(u(C)?f(C,"h")-n:C),O=f(u(O)?f(O,"h")-n:O),r=k,l=O,b.fitToView&&(k=Math.min(h.w-t,k),O=Math.min(h.h-n,O)),t=h.w-W,L=h.h-L,b.aspectRatio?(v>k&&(w=f((v=k)/c)),w>O&&(v=f((w=O)*c)),v<_&&(w=f((v=_)/c)),w<C&&(v=f((w=C)*c))):(v=Math.max(_,Math.min(v,k)),b.autoHeight&&"iframe"!==b.type&&(x.width(v),w=x.height()),w=Math.max(C,Math.min(w,O))),b.fitToView){if(x.width(v).height(w),m.width(v+S),h=m.width(),W=m.height(),b.aspectRatio)for(;(h>t||W>L)&&v>_&&w>C&&!(19<p++);)(v=f((w=Math.max(C,Math.min(O,w-10)))*c))<_&&(w=f((v=_)/c)),v>k&&(w=f((v=k)/c)),x.width(v).height(w),m.width(v+S),h=m.width(),W=m.height();else v=Math.max(_,Math.min(v,v-(h-t))),w=Math.max(C,Math.min(w,w-(W-L)))}H&&"auto"===E&&w<a&&v+S+H<t&&(v+=H),x.width(v).height(w),m.width(v+S),h=m.width(),W=m.height(),m=(h>t||W>L)&&v>_&&w>C,v=b.aspectRatio?v<r&&w<l&&v<o&&w<a:(v<r||w<l)&&(v<o||w<a),i.extend(b,{dim:{width:g(h),height:g(W)},origWidth:o,origHeight:a,canShrink:m,canExpand:v,wPadding:S,hPadding:e,wrapSpace:W-y.outerHeight(!0),skinSpace:y.height()-w}),!d&&b.autoHeight&&w>C&&w<O&&!v&&x.height("auto")},_getPosition:function(e){var t=s.current,i=s.getViewport(),n=t.margin,o=s.wrap.width()+n[1]+n[3],a=s.wrap.height()+n[0]+n[2],n={position:"absolute",top:n[0],left:n[3]};return t.autoCenter&&t.fixed&&!e&&a<=i.h&&o<=i.w?n.position="fixed":t.locked||(n.top+=i.y,n.left+=i.x),n.top=g(Math.max(n.top,n.top+(i.h-a)*t.topRatio)),n.left=g(Math.max(n.left,n.left+(i.w-o)*t.leftRatio)),n},_afterZoomIn:function(){var e=s.current;e&&(s.isOpen=s.isOpened=!0,s.wrap.css("overflow","visible").addClass("fancybox-opened"),s.update(),(e.closeClick||e.nextClick&&1<s.group.length)&&s.inner.css("cursor","pointer").bind("click.fb",function(t){i(t.target).is("a")||i(t.target).parent().is("a")||(t.preventDefault(),s[e.closeClick?"close":"next"]())}),e.closeBtn&&i(e.tpl.closeBtn).appendTo(s.skin).bind("click.fb",function(e){e.preventDefault(),s.close()}),e.arrows&&1<s.group.length&&((e.loop||0<e.index)&&i(e.tpl.prev).appendTo(s.outer).bind("click.fb",s.prev),(e.loop||e.index<s.group.length-1)&&i(e.tpl.next).appendTo(s.outer).bind("click.fb",s.next)),s.trigger("afterShow"),e.loop||e.index!==e.group.length-1?s.opts.autoPlay&&!s.player.isActive&&(s.opts.autoPlay=!1,s.play()):s.play(!1))},_afterZoomOut:function(e){e=e||s.current,i(".fancybox-wrap").trigger("onReset").remove(),i.extend(s,{group:{},opts:{},router:!1,current:null,isActive:!1,isOpened:!1,isOpen:!1,isClosing:!1,wrap:null,skin:null,outer:null,inner:null}),s.trigger("afterClose",e)}}),s.transitions={getOrigPosition:function(){var e=s.current,t=e.element,i=e.orig,n={},o=50,a=50,r=e.hPadding,l=e.wPadding,c=s.getViewport();return!i&&e.isDom&&t.is(":visible")&&((i=t.find("img:first")).length||(i=t)),h(i)?(n=i.offset(),i.is("img")&&(o=i.outerWidth(),a=i.outerHeight())):(n.top=c.y+(c.h-a)*e.topRatio,n.left=c.x+(c.w-o)*e.leftRatio),("fixed"===s.wrap.css("position")||e.locked)&&(n.top-=c.y,n.left-=c.x),{top:g(n.top-r*e.topRatio),left:g(n.left-l*e.leftRatio),width:g(o+l),height:g(a+r)}},step:function(e,t){var i,n,o=t.prop,a=(n=s.current).wrapSpace,r=n.skinSpace;("width"===o||"height"===o)&&(i=t.end===t.start?1:(e-t.start)/(t.end-t.start),s.isClosing&&(i=1-i),n=e-(n="width"===o?n.wPadding:n.hPadding),s.skin[o](f("width"===o?n:n-a*i)),s.inner[o](f("width"===o?n:n-a*i-r*i)))},zoomIn:function(){var e=s.current,t=e.pos,n=e.openEffect,o="elastic"===n,a=i.extend({opacity:1},t);delete a.position,o?(t=this.getOrigPosition(),e.openOpacity&&(t.opacity=.1)):"fade"===n&&(t.opacity=.1),s.wrap.css(t).animate(a,{duration:"none"===n?0:e.openSpeed,easing:e.openEasing,step:o?this.step:null,complete:s._afterZoomIn})},zoomOut:function(){var e=s.current,t=e.closeEffect,i="elastic"===t,n={opacity:.1};i&&(n=this.getOrigPosition(),e.closeOpacity&&(n.opacity=.1)),s.wrap.animate(n,{duration:"none"===t?0:e.closeSpeed,easing:e.closeEasing,step:i?this.step:null,complete:s._afterZoomOut})},changeIn:function(){var e,t=s.current,i=t.nextEffect,n=t.pos,o={opacity:1},a=s.direction;n.opacity=.1,"elastic"===i&&(e="down"===a||"up"===a?"top":"left","down"===a||"right"===a?(n[e]=g(f(n[e])-200),o[e]="+=200px"):(n[e]=g(f(n[e])+200),o[e]="-=200px")),"none"===i?s._afterZoomIn():s.wrap.css(n).animate(o,{duration:t.nextSpeed,easing:t.nextEasing,complete:s._afterZoomIn})},changeOut:function(){var e=s.previous,t=e.prevEffect,n={opacity:.1},o=s.direction;"elastic"===t&&(n["down"===o||"up"===o?"top":"left"]=("up"===o||"left"===o?"-":"+")+"=200px"),e.wrap.animate(n,{duration:"none"===t?0:e.prevSpeed,easing:e.prevEasing,complete:function(){i(this).trigger("onReset").remove()}})}},s.helpers.overlay={defaults:{closeClick:!0,speedOut:200,showEarly:!0,css:{},locked:!d,fixed:!0},overlay:null,fixed:!1,el:i("html"),create:function(e){e=i.extend({},this.defaults,e),this.overlay&&this.close(),this.overlay=i('<div class="fancybox-overlay"></div>').appendTo(s.coming?s.coming.parent:e.parent),this.fixed=!1,e.fixed&&s.defaults.fixed&&(this.overlay.addClass("fancybox-overlay-fixed"),this.fixed=!0)},open:function(e){var t=this;e=i.extend({},this.defaults,e),this.overlay?this.overlay.unbind(".overlay").width("auto").height("auto"):this.create(e),this.fixed||(a.bind("resize.overlay",i.proxy(this.update,this)),this.update()),e.closeClick&&this.overlay.bind("click.overlay",function(e){if(i(e.target).hasClass("fancybox-overlay"))return s.isActive?s.close():t.close(),!1}),this.overlay.css(e.css).show()},close:function(){var e,t;a.unbind("resize.overlay"),this.el.hasClass("fancybox-lock")&&(i(".fancybox-margin").removeClass("fancybox-margin"),e=a.scrollTop(),t=a.scrollLeft(),this.el.removeClass("fancybox-lock"),a.scrollTop(e).scrollLeft(t)),i(".fancybox-overlay").remove().hide(),i.extend(this,{overlay:null,fixed:!1})},update:function(){var e,i="100%";this.overlay.width(i).height("100%"),l?(e=Math.max(t.documentElement.offsetWidth,t.body.offsetWidth),r.width()>e&&(i=r.width())):r.width()>a.width()&&(i=r.width()),this.overlay.width(i).height(r.height())},onReady:function(e,t){var n=this.overlay;i(".fancybox-overlay").stop(!0,!0),n||this.create(e),e.locked&&this.fixed&&t.fixed&&(n||(this.margin=r.height()>a.height()&&i("html").css("margin-right").replace("px","")),t.locked=this.overlay.append(t.wrap),t.fixed=!1),!0===e.showEarly&&this.beforeShow.apply(this,arguments)},beforeShow:function(e,t){var n,o;t.locked&&(!1!==this.margin&&(i("*").filter(function(){return"fixed"===i(this).css("position")&&!i(this).hasClass("fancybox-overlay")&&!i(this).hasClass("fancybox-wrap")}).addClass("fancybox-margin"),this.el.addClass("fancybox-margin")),n=a.scrollTop(),o=a.scrollLeft(),this.el.addClass("fancybox-lock"),a.scrollTop(n).scrollLeft(o)),this.open(e)},onUpdate:function(){this.fixed||this.update()},afterClose:function(e){this.overlay&&!s.coming&&this.overlay.fadeOut(e.speedOut,i.proxy(this.close,this))}},s.helpers.title={defaults:{type:"float",position:"bottom"},beforeShow:function(e){var t=s.current,n=t.title,o=e.type;if(i.isFunction(n)&&(n=n.call(t.element,t)),p(n)&&""!==i.trim(n)){switch(t=i('<div class="fancybox-title fancybox-title-'+o+'-wrap">'+n+"</div>"),o){case"inside":o=s.skin;break;case"outside":o=s.wrap;break;case"over":o=s.inner;break;default:o=s.skin,t.appendTo("body"),l&&t.width(t.width()),t.wrapInner('<span class="child"></span>'),s.current.margin[2]+=Math.abs(f(t.css("margin-bottom")))}t["top"===e.position?"prependTo":"appendTo"](o)}}},i.fn.fancybox=function(e){var t,n=i(this),o=this.selector||"",a=function(a){var r,l,c=i(this).blur(),d=t;a.ctrlKey||a.altKey||a.shiftKey||a.metaKey||c.is(".fancybox-wrap")||(r=e.groupAttr||"data-fancybox-group",(l=c.attr(r))||(r="rel",l=c.get(0)[r]),l&&""!==l&&"nofollow"!==l&&(d=(c=(c=o.length?i(o):n).filter("["+r+'="'+l+'"]')).index(this)),e.index=d,!1!==s.open(c,e)&&a.preventDefault())};return t=(e=e||{}).index||0,o&&!1!==e.live?r.undelegate(o,"click.fb-start").delegate(o+":not('.fancybox-item, .fancybox-nav')","click.fb-start",a):n.unbind("click.fb-start").bind("click.fb-start",a),this.filter("[data-fancybox-start=1]").trigger("click"),this},r.ready(function(){var t,a;if(i.scrollbarWidth===n&&(i.scrollbarWidth=function(){var e=i('<div style="width:50px;height:50px;overflow:auto"><div/></div>').appendTo("body"),t=e.children(),t=t.innerWidth()-t.height(99).innerWidth();return e.remove(),t}),i.support.fixedPosition===n){t=i.support;var r=20===(a=i('<div style="position:fixed;top:20px;"></div>').appendTo("body"))[0].offsetTop||15===a[0].offsetTop;a.remove(),t.fixedPosition=r}i.extend(s.defaults,{scrollbarWidth:i.scrollbarWidth(),fixed:i.support.fixedPosition,parent:i("body")}),t=i(e).width(),o.addClass("fancybox-lock-test"),a=i(e).width(),o.removeClass("fancybox-lock-test"),i("<style type='text/css'>.fancybox-margin{margin-right:"+(a-t)+"px;}</style>").appendTo("head")})}(window,document,jQuery),$(document).ready(function(){$(".fancybox").fancybox({openEffect:"fade",closeEffect:"fade"})});
| ver. 1.4 |
Github
|
.
| PHP 7.4.33 | Generation time: 0.02 |
proxy
|
phpinfo
|
Settings