$(document).ready(function(){function r(){n<2?($("#scrollCount").val(n+1),n=n+1):(n==2&&(u(),f(),e()),n=n+1)}function u(){$(".lazyLoading").each(function(){$(this).attr("src",$(this).attr("data-image"));$(this).css("background-color","transparent")});$(".news-letter_bg").addClass("news-letter").removeClass("news-letter_bg");console.log("Add Image End")}function f(){if(document.getElementById("divchat").getAttribute("data-status")==0){var n=document.createElement("script"),t=document.createElement("script"),i=document.createElement("script");n.type="text/javascript";t.type="text/javascript";i.type="text/javascript";n.text="(function(t,e){var r=function(t){try{var r=e.head||e.getElementsByTagName('head')[0];a=e.createElement('script');a.setAttribute('type','text/javascript');a.setAttribute('src',t);r.appendChild(a);}catch(t){}};t.CollectId = '5c471aca07fa985819430379';r('https://collectcdn.com/launcher.js');})(window,document);";t.text="var collectchat = collectchat || {}; collectchat.ready = function() { collectchat.config({openOnLoad:true});}";i.text="var collectchat = collectchat || {}; collectchat.ready = function() {collectchat.on('complete', function() {window.location='https://www.asapholidays.com/Thanks';});}";document.getElementById("divchat").appendChild(n);document.getElementById("divchat").appendChild(t);document.getElementById("divchat").appendChild(i);document.getElementById("divchat").setAttribute("data-status","1")}}function e(){var n,t,i,r,u;if(document.getElementById("divgoogletag").getAttribute("data-status")==0){var e=4567890,o=Math.floor(Math.random()*(9876540-+e))+ +e,f=document.createElement("script");f.type="application/ld+json";f.text=" {'@context': 'http://schema.org','@type': 'Organization','url': 'https://www.asapholidays.com','logo': 'https://www.asapholidays.com/Content/images/logo.png','contactPoint': [{'@type': 'ContactPoint','telephone': '+91-172-5071021','contactType': 'customer service'}]}";n=document.createElement("script");n.type="text/javascript";n.src="/Scripts/Google/Google-Analytics.js?id=UA-115769706-1&amp;v="+o+")";t=document.createElement("script");t.type="text/javascript";t.text="window.dataLayer = window.dataLayer || [];function gtag() { dataLayer.push(arguments); }gtag('js', new Date());gtag('config', 'UA-115769706-1');";i=document.createElement("script");i.type="text/javascript";i.src="/Scripts/google/Google-AdWords.js?id=AW-812924937&amp;v="+o+")";r=document.createElement("script");r.type="text/javascript";r.text="window.dataLayer = window.dataLayer || [];function gtag() { dataLayer.push(arguments); }gtag('js', new Date());gtag('config', 'AW-812924937');";u=document.createElement("script");u.type="text/javascript";u.text="(function(d, w) { var x = d.getElementsByTagName('SCRIPT')[0]; var g = d.createElement('SCRIPT'); g.type = 'text/javascript'; g.async = true; g.src = ('https:' == d.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; x.parentNode.insertBefore(g, x); var f = function () { var x = d.getElementsByTagName('SCRIPT')[0]; var s = d.createElement('SCRIPT'); s.type = 'text/javascript'; s.async = true; s.src = '//np.lexity.com/ca6f2316'; x.parentNode.insertBefore(s, x); }; w.attachEvent ? w.attachEvent('onload', f) : w.addEventListener('load', f, false); }(document, window));";document.getElementById("divgoogletag").appendChild(f);document.getElementById("divgoogletag").appendChild(n);document.getElementById("divgoogletag").appendChild(t);document.getElementById("divgoogletag").appendChild(i);document.getElementById("divgoogletag").appendChild(r);document.getElementById("divgoogletag").appendChild(u);document.getElementById("divgoogletag").setAttribute("data-status","1")}}function h(){document.getElementById("mysid_nav").style.width="300px"}function c(){document.getElementById("mysid_nav").style.width="0"}var t,n;setTimeout(function(){$(".lazyLoading").each(function(){$(this).attr("class").indexOf("homePageBanner")>-1&&$(this).attr("src",$(this).attr("data-image"))})},1e3);t=window.top.location.href;t.toLocaleLowerCase().indexOf("payment")<0&&(n=0,window.onscroll=r);$(window).scroll(function(){var n=$(window).scrollTop();n>=100?$(".headerdiv_t").addClass("fixed_header"):$(".headerdiv_t").removeClass("fixed_header")});var i=["+911140014001","+911725071021"],o=new Date,s=o.getSeconds();s%2==0?$("#clicktocall").attr("href","tel:"+i[1]):$("#clicktocall").attr("href","tel:"+i[0]);$(".signindiv").click(function(){$("#divsignin").show();$("#divsignup").hide();$("#forgetpassworddiv").hide()});$(".signupdiv").click(function(){$("#divsignin").hide();$("#divsignup").show();$("#forgetpassworddiv").hide()});$("#alreadyaccount").click(function(){$("#divsignin").show();$("#divsignup").hide();$("#forgetpassworddiv").hide()});$("#createaccount").click(function(){$("#divsignin").hide();$("#divsignup").show();$("#forgetpassworddiv").hide()});$("#accountsignin").click(function(){$("#divsignin").show();$("#divsignup").hide();$("#forgetpassworddiv").hide()});$("#forgetpassword").click(function(){$("#divsignin").hide();$("#divsignup").hide();$("#forgetpassworddiv").show()});$(".openMenu").click(function(){h()});$(".closeMenu").click(function(){c()});$("#txtHomeSearch").autocomplete({source:function(n,t){$.ajax({url:"/CMS/Control/SelectHomePageSearch/",type:"POST",dataType:"json",data:{Prefix:n.term},success:function(n){t($.map(n,function(n){return{label:n,value:n}}))}})},select:function(n,t){this.value=t.item.value;window.location.href="/Package?HomePackageSearch="+this.value},messages:{noResults:"",results:""}});$(".btnSignIn").click(function(){if(ShowLoader(),email=$("#txtEmailSignIn").val(),pass=$("#txtPasswordSignIn").val(),email=="")return HideLoader(),ShowAlert("Please provide Email address"),$("#txtEmailSignIn").focus(),!1;if(pass=="")return HideLoader(),ShowAlert("Please provide Password"),$("#txtPasswordSignIn").focus(),!1;var n={CustomerEmailId:email,CustomerPassword:pass},t=JSON.stringify(n);$.ajax({type:"POST",url:"/Home/SignIn",contentType:"application/json; charset=utf-8",data:t,dataType:"json",success:function(n){n.Status==1?(HideLoader(),$("#txtEmailSignIn").val(""),$("#txtPasswordSignIn").val(""),$("#btnClose").click(),window.location.reload()):n.Status==2?(HideLoader(),ShowAlert(n.Message)):(HideLoader(),ShowAlert(n.Message))},error:function(){HideLoader()},complete:function(){HideLoader()}})});$(".btnSignUp").click(function(){if(ShowLoader(),name=$("#txtNameSignUp").val(),contact=$("#txtContactSignUp").val(),email=$("#txtEmailSignUp").val(),pass=$("#txtPasswordSignUp").val(),name=="")return HideLoader(),ShowAlert("Please provide Name"),$("#txtNameSignUp").focus(),!1;if(contact=="")return HideLoader(),ShowAlert("Please provide Contact Number"),$("#txtContactSignUp").focus(),!1;if(isNaN(contact))return HideLoader(),ShowAlert("The Contact Number must be numeric only"),$("#txtContactSignUp").focus(),!1;if(contact.length<10||contact.length>16)return HideLoader(),ShowAlert("The Contact Number must be at least 10 to 16 characters long"),$("#txtContactSignUp").focus(),!1;if(email=="")return HideLoader(),ShowAlert("Please provide Email address"),$("#txtEmailSignUp").focus(),!1;if(isEmailValid(email)){if(pass=="")return HideLoader(),ShowAlert("Please provide Password"),$("#txtPasswordSignUp").focus(),!1;if(pass.length<8||pass.length>=35)return HideLoader(),ShowAlert("Password must be 8 to 36 characters long."),$("#txtPasswordSignUp").focus(),!1}else return HideLoader(),ShowAlert("Please enter a valid email address"),$("#txtEmailSignUp").focus(),!1;var n={CustomerName:name,CustomerEmailId:email,CutomerContactNo:contact,CustomerPassword:pass},t=JSON.stringify(n);$.ajax({type:"POST",url:"/Home/SignUp",contentType:"application/json; charset=utf-8",data:t,dataType:"json",success:function(n){n.Status==1?(HideLoader(),$("#txtNameSignUp").val(""),$("#txtContactSignUp").val(""),$("#txtEmailSignUp").val(""),$("#txtPasswordSignUp").val(""),$("#btnClose").click(),ShowAlert(n.Message)):n.Status==2?(HideLoader(),ShowAlert(n.Message)):(HideLoader(),ShowAlert(n.Message))},error:function(){HideLoader()},complete:function(){HideLoader()}})});$(".btnSignOut").click(function(){location.href="/Home/SignOut"});$(".btnForget").click(function(){if(ShowLoader(),email=$("#txtEmailForgetPassword").val(),email=="")return HideLoader(),ShowAlert("Please provide Email address"),$("#txtEmailForgetPassword").focus(),!1;if(!isEmailValid(email))return HideLoader(),ShowAlert("Please enter a valid email address"),$("#txtEmailForgetPassword").focus(),!1;$.ajax({type:"POST",url:"/Home/ForgetPassword?emailId="+email,contentType:"application/json; charset=utf-8",data:"",dataType:"json",success:function(n){n.Status==1?(HideLoader(),$("#txtEmailForgetPassword").val(""),$("#btnClose").click(),ShowAlert(n.Message)):n.Status==2?(HideLoader(),ShowAlert(n.Message)):(HideLoader(),ShowAlert(n.Message))},error:function(){HideLoader()},complete:function(){HideLoader()}})});$(".nameLink").click(function(){location.href="/Dashboard"});$("#btnnewsletter").unbind().click(function(){var n=$("#txtnewsletter").val();if(n!=""&&/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,5})+$/.test(n))try{$.ajax({url:"/Home/Newsletter",type:"POST",data:{emailid:n},success:function(n){n=="true"?($("#txtnewsletter").val(""),$("#subscribe").modal("show")):($("#txtnewsletter").val(""),ShowErrorModal("Something Went Wrong Please try again..."))}})}catch(t){alert(t)}else return ShowAlert("Please provide valid email id."),$("#txtnewsletter").focus(),!1});SendDetailsEmail=function(n){n.Message==!0?($("#resetQuery").click(),window.location.href="../Thanks"):n.Message==!1&&alert("Oops some error occured. please try again.")};OnBeginQuery=function(){$(".loadingdivforquery").show()};OnCompleteQuery=function(){$(".close").click();$(".loadingdivforquery").hide()}});ShowLoader=function(){$(".loadingdivforquery").show()};HideLoader=function(){$(".loadingdivforquery").hide()};isEmailValid=function(n){return/^([a-zA-Z0-9_.+-])+\@(([a-zA-Z0-9-])+\.)+([a-zA-Z0-9]{2,4})+$/.test(n)};ShowAlert=function(n){$("#errorAlertBox").modal("show");$("#errorText").html(n)};ShowErrorModal=function(n){$("#errorAlertBox").modal("show");$("#errorText").html(n)};+function(n){"use strict";function i(i){return this.each(function(){var u=n(this),r=u.data("bs.affix"),f=typeof i=="object"&&i;r||u.data("bs.affix",r=new t(this,f));typeof i=="string"&&r[i]()})}var t=function(i,r){this.options=n.extend({},t.DEFAULTS,r);this.$target=n(this.options.target).on("scroll.bs.affix.data-api",n.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",n.proxy(this.checkPositionWithEventLoop,this));this.$element=n(i);this.affixed=null;this.unpin=null;this.pinnedOffset=null;this.checkPosition()},r;t.VERSION="3.3.7";t.RESET="affix affix-top affix-bottom";t.DEFAULTS={offset:0,target:window};t.prototype.getState=function(n,t,i,r){var u=this.$target.scrollTop(),f=this.$element.offset(),e=this.$target.height();if(i!=null&&this.affixed=="top")return u<i?"top":!1;if(this.affixed=="bottom")return i!=null?u+this.unpin<=f.top?!1:"bottom":u+e<=n-r?!1:"bottom";var o=this.affixed==null,s=o?u:f.top,h=o?e:t;return i!=null&&u<=i?"top":r!=null&&s+h>=n-r?"bottom":!1};t.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(t.RESET).addClass("affix");var n=this.$target.scrollTop(),i=this.$element.offset();return this.pinnedOffset=i.top-n};t.prototype.checkPositionWithEventLoop=function(){setTimeout(n.proxy(this.checkPosition,this),1)};t.prototype.checkPosition=function(){var i,e,o;if(this.$element.is(":visible")){var s=this.$element.height(),r=this.options.offset,f=r.top,u=r.bottom,h=Math.max(n(document).height(),n(document.body).height());if(typeof r!="object"&&(u=f=r),typeof f=="function"&&(f=r.top(this.$element)),typeof u=="function"&&(u=r.bottom(this.$element)),i=this.getState(h,s,f,u),this.affixed!=i){if(this.unpin!=null&&this.$element.css("top",""),e="affix"+(i?"-"+i:""),o=n.Event(e+".bs.affix"),this.$element.trigger(o),o.isDefaultPrevented())return;this.affixed=i;this.unpin=i=="bottom"?this.getPinnedOffset():null;this.$element.removeClass(t.RESET).addClass(e).trigger(e.replace("affix","affixed")+".bs.affix")}i=="bottom"&&this.$element.offset({top:h-s-u})}};r=n.fn.affix;n.fn.affix=i;n.fn.affix.Constructor=t;n.fn.affix.noConflict=function(){return n.fn.affix=r,this};n(window).on("load",function(){n('[data-spy="affix"]').each(function(){var r=n(this),t=r.data();t.offset=t.offset||{};t.offsetBottom!=null&&(t.offset.bottom=t.offsetBottom);t.offsetTop!=null&&(t.offset.top=t.offsetTop);i.call(r,t)})});setTimeout(function(){n.ajax({url:"/home/Testimonials/",contentType:"application/html; charset=utf-8",type:"POST",cache:!1,datatype:"html",success:function(t){n(".divTestimonials").html(t)},error:function(){}})},2e3)}(jQuery);$(document).ready(function(){var n=$(".owl-carousel");n.owlCarousel({loop:!0,nav:!0,dots:!1,margin:20,autoplay:!0,autoplayTimeout:3e3,autoplayHoverPause:!0,responsive:{0:{items:1},768:{items:2},1e3:{items:3}}})})