sito web:Prenota direttamente con albergatore. Riceverai il miglior accordo e servizio.soddisfare
/**/ img.wp-smiley,img.emoji{ display:inline!important; border:none!important; box-shadow:none!important; height:1em!important; width:1em!important; margin:00.07em!important; vertical-align:-0.1em!important; background:none!important; padding:0!important; }/*!Thisfileisauto-generated*/.wp-block-button__link{color:#fff;background-color:#c;border-radius:9999px;box-shadow:none;text-decoration:none;padding:calc(.667em+2px)calc(1.333em+2px);font-size:1.125em}.wp-block-file__button{background:#c;color:#fff;text-decoration:none}:root{--wp--preset--aspect-ratio--square:1;--wp--preset--aspect-ratio--4-3:4/3;--wp--preset--aspect-ratio--3-4:3/4;--wp--preset--aspect-ratio--3-2:3/2;--wp--preset--aspect-ratio--2-3:2/3;--wp--preset--aspect-ratio--16-9:16/9;--wp--preset--aspect-ratio--9-16:9/16;--wp--preset--color--black:#;--wp--preset--color--cyan-bluish-gray:#abb8c3;--wp--prePrenota direttamente con albergatore. Riceverai il miglior accordo e servizio.set--color--white:#ffffff;--wp--preset--color--pale-pink:#f78da7;--wp--preset--color--vivid-red:#cf2e2e;--wp--preset--color--luminous-vivid-orange:#ff6900;--wp--preset--color--luminous-vivid-amber:#fcb900;--wp--preset--color--light-green-cyan:#7bdcb5;--wp--preset--color--vivid-green-cyan:#00d084;--wp--preset--color--pale-cyan-blue:#8ed1fc;--wp--preset--color--vivid-cyan-blue:#0693e3;--wp--preset--color--vivid-purple:#9b51e0;--wp--preset--gradient--vivid-cyan-blue-to-vivid-purple:linear-gradient(135deg,rgba(6,147,227,1)0%,rgb(155,81,224)100%);--wp--preset--gradient--light-green-cyan-to-vivid-green-cyan:linear-gradient(135deg,rgb(122,220,180)0%,rgb(0,208,130)100%);--wp--preset--gradient--luminous-vivid-amber-to-luminous-vivid-orange:linear-gradient(135deg,rgba(252,185,0,1)0%,rgba(255,105,0,1)100%);--wp--preset--gradient--luminous-vivid-orange-to-vivid-red:linear-gradient(135deg,rgba(255,105,0,1)0%,rgb(207,46,46)100%);--wp--preset--gradient--very-light-gray-to-cyan-bluish-gray:linear-gradient(135deg,rgb(238,238,238)0%,rgb(169,184,195)100%);--wp--preset--gradient--cool-to-warm-spectrum:linear-gradient(135deg,rgb(74,234,220)0%,rgb(151,120,209)20%,rgb(207,42,186)40%,rgb(238,44,130)60%,rgb(251,105,98)80%,rgb(254,248,76)100%);--wp--preset--gradient--blush-light-purple:linear-gradient(135deg,rgb(255,206,236)0%,rgb(152,150,240)100%);--wp--preset--gradient--blush-bordeaux:linear-gradient(135deg,rgb(254,205,165)0%,rgb(254,45,45)50%,rgb(107,0,62)100%);--wp--preset--gradient--luminous-dusk:linear-gradient(135deg,rgb(255,203,112)0%,rgb(199,81,192)50%,rgb(65,88,208)100%);--wp--preset--gradient--pale-ocean:linear-gradient(135deg,rgb(255,245,203)0%,rgb(182,227,212)50%,rgb(51,167,181)100%);--wp--preset--gradient--electric-grass:linear-gradient(135deg,rgb(202,248,128)0%,rgb(113,206,126)100%);--wp--preset--gradient--midnight:linear-gradient(135deg,rgb(2,3,129)0%,rgb(40,116,252)100%);--wp--preset--font-size--small:13px;--wp--preset--font-size--medium:20px;--wp--preset--font-size--large:36px;--wp--preset--font-size--x-large:42px;--wp--preset--spacing--20:0.44rem;--wp--preset--spacing--30:0.67rem;--wp--preset--spacing--40:1rem;--wp--preset--spacing--50:1.5rem;--wp--preset--spacing--60:2.25rem;--wp--preset--spacing--70:3.38rem;--wp--preset--spacing--80:5.06rem;--wp--preset--shadow--natural:6px6px9pxrgba(0,0,0,0.2);--wp--preset--shadow--deep:12px12px50pxrgba(0,0,0,0.4);--wp--preset--shadow--sharp:6px6px0pxrgba(0,0,0,0.2);--wp--preset--shadow--outlined:6px6px0px-3pxrgba(255,255,255,1),6px6pxrgba(0,0,0,1);--wp--preset--shadow--crisp:6px6px0pxrgba(0,0,0,1);}:where(.is-layout-flex){gap:0.5em;}:where(.is-layout-grid){gap:0.5em;}body.is-layout-flex{display:flex;}.is-layout-flex{flex-wrap:wrap;align-items:center;}.is-layout-flex>:is(*,div){margin:0;}body.is-layout-grid{display:grid;}.is-layout-grid>:is(*,div){margin:0;}:where(.wp-block-columns.is-layout-flex){gap:2em;}:where(.wp-block-columns.is-layout-grid){gap:2em;}:where(.wp-block-post-template.is-layout-flex){gap:1.25em;}:where(.wp-block-post-template.is-layout-grid){gap:1.25em;}.has-black-color{color:var(--wp--preset--color--black)!important;}.has-cyan-bluish-gray-color{color:var(--wp--preset--color--cyan-bluish-gray)!important;}.has-white-color{color:var(--wp--preset--color--white)!important;}.has-pale-pink-color{color:var(--wp--preset--color--pale-pink)!important;}.has-vivid-red-color{color:var(--wp--preset--color--vivid-red)!important;}.has-luminous-vivid-orange-color{color:var(--wp--preset--color--luminous-vivid-orange)!important;}.has-luminous-vivid-amber-color{color:var(--wp--preset--color--luminous-vivid-amber)!important;}.has-light-green-cyan-color{color:var(--wp--preset--color--light-green-cyan)!important;}.has-vivid-green-cyan-color{color:var(--wp--preset--color--vivid-green-cyan)!important;}.has-pale-cyan-blue-color{color:var(--wp--preset--color--pale-cyan-blue)!important;}.has-vivid-cyan-blue-color{color:var(--wp--preset--color--vivid-cyan-blue)!important;}.has-vivid-purple-color{color:var(--wp--preset--color--vivid-purple)!important;}.has-black-background-color{background-color:var(--wp--preset--color--black)!important;}.has-cyan-bluish-gray-background-color{background-color:var(--wp--preset--color--cyan-bluish-gray)!important;}.has-white-background-color{background-color:var(--wp--preset--color--white)!important;}.has-pale-pink-background-color{background-color:var(--wp--preset--color--pale-pink)!important;}.has-vivid-red-background-color{background-color:var(--wp--preset--color--vivid-red)!important;}.has-luminous-vivid-orange-background-color{background-color:var(--wp--preset--color--luminous-vivid-orange)!important;}.has-luminous-vivid-amber-background-color{background-color:var(--wp--preset--color--luminous-vivid-amber)!important;}.has-light-green-cyan-background-color{background-color:var(--wp--preset--color--light-green-cyan)!important;}.has-vivid-green-cyan-background-color{background-color:var(--wp--preset--color--vivid-green-cyan)!important;}.has-pale-cyan-blue-background-color{background-color:var(--wp--preset--color--pale-cyan-blue)!important;}.has-vivid-cyan-blue-background-color{background-color:var(--wp--preset--color--vivid-cyan-blue)!important;}.has-vivid-purple-background-color{background-color:var(--wp--preset--color--vivid-purple)!important;}.has-black-border-color{border-color:var(--wp--preset--color--black)!important;}.has-cyan-bluish-gray-border-color{border-color:var(--wp--preset--color--cyan-bluish-gray)!important;}.has-white-border-color{border-color:var(--wp--preset--color--white)!important;}.has-pale-pink-border-color{border-color:var(--wp--preset--color--pale-pink)!important;}.has-vivid-red-border-color{border-color:var(--wp--preset--color--vivid-red)!important;}.has-luminous-vivid-orange-border-color{border-color:var(--wp--preset--color--luminous-vivid-orange)!important;}.has-luminous-vivid-amber-border-color{border-color:var(--wp--preset--color--luminous-vivid-amber)!important;}.has-light-green-cyan-border-color{border-color:var(--wp--preset--color--light-green-cyan)!important;}.has-vivid-green-cyan-border-color{border-color:var(--wp--preset--color--vivid-green-cyan)!important;}.has-pale-cyan-blue-border-color{border-color:var(--wp--preset--color--pale-cyan-blue)!important;}.has-vivid-cyan-blue-border-color{border-color:var(--wp--preset--color--vivid-cyan-blue)!important;}.has-vivid-purple-border-color{border-color:var(--wp--preset--color--vivid-purple)!important;}.has-vivid-cyan-blue-to-vivid-purple-gradient-background{background:var(--wp--preset--gradient--vivid-cyan-blue-to-vivid-purple)!important;}.has-light-green-cyan-to-vivid-green-cyan-gradient-background{background:var(--wp--preset--gradient--light-green-cyan-to-vivid-green-cyan)!important;}.has-luminous-vivid-amber-to-luminous-vivid-orange-gradient-background{background:var(--wp--preset--gradient--luminous-vivid-amber-to-luminous-vivid-orange)!important;}.has-luminous-vivid-orange-to-vivid-red-gradient-background{background:var(--wp--preset--gradient--luminous-vivid-orange-to-vivid-red)!important;}.has-very-light-gray-to-cyan-bluish-gray-gradient-background{background:var(--wp--preset--gradient--very-light-gray-to-cyan-bluish-gray)!important;}.has-cool-to-warm-spectrum-gradient-background{background:var(--wp--preset--gradient--cool-to-warm-spectrum)!important;}.has-blush-light-purple-gradient-background{background:var(--wp--preset--gradient--blush-light-purple)!important;}.has-blush-bordeaux-gradient-background{background:var(--wp--preset--gradient--blush-bordeaux)!important;}.has-luminous-dusk-gradient-background{background:var(--wp--preset--gradient--luminous-dusk)!important;}.has-pale-ocean-gradient-background{background:var(--wp--preset--gradient--pale-ocean)!important;}.has-electric-grass-gradient-background{background:var(--wp--preset--gradient--electric-grass)!important;}.has-midnight-gradient-background{background:var(--wp--preset--gradient--midnight)!important;}.has-small-font-size{font-size:var(--wp--preset--font-size--small)!important;}.has-medium-font-size{font-size:var(--wp--preset--font-size--medium)!important;}.has-large-font-size{font-size:var(--wp--preset--font-size--large)!important;}.has-x-large-font-size{font-size:var(--wp--preset--font-size--x-large)!important;}:where(.wp-block-post-template.is-layout-flex){gap:1.25em;}:where(.wp-block-post-template.is-layout-grid){gap:1.25em;}:where(.wp-block-columns.is-layout-flex){gap:2em;}:where(.wp-block-columns.is-layout-grid){gap:2em;}:root:where(.wp-block-pullquote){font-size:1.5em;line-height:1.6;}body.modal-open#wpadminbar{z-index:999}.embed-responsive-16by9.fluid-width-video-wrapper{padding:0!important;position:initial} .ds-top-header{ color:#081ac6; } .ds-top-headera, .ds-top-headera:visited{ color:#081ac6!important; } .ds-top-headera:hover{ color:#081ac6!important; } .ds-top-header{ background-color:#081ac6; } .site-headerhgroupa{ color:!important; } .site-headera,.site-headera:visited{ color:#FFFFFF!important; } .site-headera:hover,.site-headera:focus,.site-headera:active,.site-headera:visited:hover,.site-headera:visited:focus,.site-headera:visited:active{ color:#081ac6!important; } .site-header{ background-color:#081ac6; } #primary-nul.sub-menua,#primary-nul.sub-menu,#primary-nul.greedy-links{ background-color:#081ac6; } #primary-nul.greedy-links:before{ display:none; } #primary-nul.sub-menua:hover,#primary-nul.greedy-linksa:hover{ background-color:#081ac6; } @media(max-width:992px){ #primary-nullia:hover{ background:#081ac6; } } h1,.h1,h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6,#simplemodal-containerh3{ color:#6c757d; } #simplemodal-containerh3{ font-family:'Lato','HelveticaNeue',Helvetica,Arial,sans-serif; } .bsuia:not(.btn){ color:; } .bsuia:not(.btn):hover, .bsuia:not(.btn):visited:hover, .bsuia:not(.btn):focus, .bsuia:not(.btn):active{ color:; } .bsuia:not(.btn):visited{ color:; } .bsui.content-box,.bsui.content.entry,.bsui#geodir_content,.bsui.sidebar.widget,.bsui.geodir-content-left.geodir-company_info,.bsui.geodir-content-right.geodir-company_info,.bsui.geodir_full_pe.geodir-category-list-in,.bsui.geodir_full_pe.geodir-loc-bar{ background-color:#FFFFFF; border-color:#FFFFFF!important; } .bsuibody{ font-family:'Lato','HelveticaNeue',Helvetica,Arial,sans-serif; font-size:16px; line-height:20px; color:#6c757d; background-color:#F8F9FA; } bsuip{ line-height:22px; } .footer-widgets{ color:#081ac6; } .footer-widgetsh1, .footer-widgets.h1, .footer-widgetsh2, .footer-widgets.h2, .footer-widgetsh3, .footer-widgets.h3, .footer-widgetsh4, .footer-widgets.h4, .footer-widgetsh5, .footer-widgets.h5, .footer-widgetsh6, .footer-widgets.h6{ color:#081ac6; } .footer-widgetsa{ color:#081ac6; } .footer-widgetsa:hover, .footer-widgetsa:visited:hover, .footer-widgetsa:focus, .footer-widgetsa:active{ color:#081ac6; } .footer-widgetsa:visited{ color:#081ac6; } #footer.footer-widgets{ background-color:#081ac6; border-top-color:#081ac6!important; border-bottom-color:#081ac6!important; } #footer.{ color:#081ac6; } #footer.a{ color:#081ac6; } #footer.a:hover, #footer.a:visited:hover, #footer.a:focus, #footer.a:active{ color:#081ac6; } #footer.a:visited{ color:#081ac6; } #footer.{ background-color:#081ac6; border-top:1pxsolid#; border-top-color:#081ac6!important; } .fullwidth-sidebar-container.geodir-wgt-map, .fullwidth-sidebar-container.geodir-post-slider{ padding:0; } ul,li{ list-style:none; padding-left:0; } /*=WordPressCore --------------------------------------------------------------*/ .alignnone{ margin:5px20px20px0; } .aligncenter, div.aligncenter{ display:block; margin:5pxauto5pxauto; } .alignright{ float:right; } .alignleft{ float:left; } aimg.alignright{ float:right; margin:5px020px20px; } aimg.alignnone{ margin:5px20px20px0; } aimg.alignleft{ float:left; margin:5px20px20px0; } aimg.aligncenter{ display:block; margin-left:auto; margin-right:auto; } .wp-caption{ background:#fff; border:1pxsolid#f0f0f0; max-width:96%;/*Imedoesnotoverflowthecontentarea*/ padding:5px3px10px; text-align:center; } .wp-caption.alignnone{ margin:5px20px20px0; } .wp-caption.alignleft{ margin:5px20px20px0; } .wp-caption.alignright{ margin:5px020px20px; } .wp-captionimg{ border:0none; height:auto; margin:0; max-width:98.5%; padding:0; width:auto; } .wp-captionp.wp-caption-text{ font-size:11px; line-height:17px; margin:0; padding:04px5px; } /*Textmeantonlyforscreenreaders.*/ .screen-reader-text{ border:0; clip:rect(1px,1px,1px,1px); clip-path:inset(50%); height:1px; margin:-1px; overflow:hidden; padding:0; position:absolute!important; width:1px; word-wrap:normal!important;/*Manyscreenreaderandbrowsercombinationsannouncebrokenwordsastheywouldappearvisually.*/ } .screen-reader-text:focus{ background-color:#eee; clip:auto!important; clip-path:none; color:#444; display:block; font-size:1em; height:auto; left:5px; line-height:normal; padding:15px23px14px; text-decoration:none; top:5px; width:auto; z-index:; /*AboveWPtoolbar.*/ }/**//**//*1&&requiredSpace>ailableSpace){var$li=$vlinks.children().last().prev();$li.addClass(ddItemClass);if(!jQuery($hlinks).children().length){$li.find('.n-link').addClass('rounded-0rounded-bottom')}else{jQuery($hlinks).find('.n-link').removeClass('rounded-top');$li.find('.n-link').addClass('rounded-0rounded-top')}$li.prependTo($hlinks);numOfVisibleItems-=1;check()}elseif(ailableSpace>breakWidths[numOfVisibleItems]){$hlinks.children().first().insertBefore($btn);numOfVisibleItems+=1;check()}jQuery($btn).find(".greedy-count").html(numOfItems-numOfVisibleItems);if(numOfVisibleItems===numOfItems){$btn.addClass('d-none')}else$btn.removeClass('d-none')}jQuery(window).on("resize",function(){check()});check()})}functionaui_select2_locale(){varaui_select2_params={"i18n_select_state_text":"Selectanoption\u2026","i18n_no_matches":"Nomatchesfound","i18n_ajax_error":"Loadingfailed","i18n_input_too_short_1":"Pleaseenter1ormorecharacters","i18n_input_too_short_n":"Pleaseenter%item%ormorecharacters","i18n_input_too_long_1":"Pleasedelete1character","i18n_input_too_long_n":"Pleasedelete%item%characters","i18n_selection_too_long_1":"Youcanonlyselect1item","i18n_selection_too_long_n":"Youcanonlyselect%item%items","i18n_load_more":"Loadingmoreresults\u2026","i18n_searching":"Searching\u2026"};return{theme:"bootstrap-5",width:jQuery(this).data('width')?jQuery(this).data('width'):jQuery(this).hasClass('w-100')?'100%':'style',placeholder:jQuery(this).data('placeholder'),langue:{errorLoading:function(){returnaui_select2_params.i18n_searching},inputTooLong:function(args){varoverChars=args.input.length-args.maximum;if(1===overChars){returnaui_select2_params.i18n_input_too_long_1}returnaui_select2_params.i18n_input_too_long_n.replace('%item%',overChars)},inputTooShort:function(args){varremainingChars=args.minimum-args.input.length;if(1===remainingChars){returnaui_select2_params.i18n_input_too_short_1}returnaui_select2_params.i18n_input_too_short_n.replace('%item%',remainingChars)},loadingMore:function(){returnaui_select2_params.i18n_load_more},maximumSelected:function(args){if(args.maximum===1){returnaui_select2_params.i18n_selection_too_long_1}returnaui_select2_params.i18n_selection_too_long_n.replace('%item%',args.maximum)},noResults:function(){returnaui_select2_params.i18n_no_matches},searching:function(){returnaui_select2_params.i18n_searching}}}}functionaui_init_select2(){varselect2_args=jQuery.extend({},aui_select2_locale());jQuery("select.aui-select2").each(function(){if(!jQuery(this).hasClass("select2-hidden-accessible")){jQuery(this).select2(select2_args)}})}functionaui_time_o(selector){varaui_timeo_params={"prefix_o":"","suffix_o":"o","prefix_after":"after","suffix_after":"","seconds":"lessthanaminute","minute":"aboutaminute","minutes":"%dminutes","hour":"aboutanhour","hours":"about%dhours","day":"aday","days":"%ddays","month":"aboutamonth","months":"%dmonths","year":"aboutayear","years":"%dyears"};vartemplates={prefix:aui_timeo_params.prefix_o,suffix:aui_timeo_params.suffix_o,seconds:aui_timeo_params.seconds,minute:aui_timeo_params.minute,minutes:aui_timeo_params.minutes,hour:aui_timeo_params.hour,hours:aui_timeo_params.hours,day:aui_timeo_params.day,days:aui_timeo_params.days,month:aui_timeo_params.month,months:aui_timeo_params.months,year:aui_timeo_params.year,years:aui_timeo_params.years};vartemplate=function(t,n){returntemplates[t]&&templates[t].replace(/%d/i,Math.abs(Math.round(n)))};vartimer=function(time){if(!time)return;time=time.replace(/\.\d+/,"");time=time.replace(/-/,"/").replace(/-/,"/");time=time.replace(/T/,"").replace(/Z/,"UTC");time=time.replace(/([\+\-]\d\d)\:?(\d\d)/,"$1$2");time=newDate(time*1000||time);varnow=newDate();varseconds=((now.getTime()-time)*.001)>>0;varminutes=seconds/60;varhours=minutes/60;vardays=hours/24;varyears=days/365;returntemplates.prefix+(seconds0){$placeholder_count=$md_count-$new_item_count;while($placeholder_count>0){$new_items+='';$placeholder_count--}}$new_items+=''}jQuery($carousel).find('.carousel-inner').addClass('aui-multiple-items').html($new_items);jQuery($carousel).find('.carousel-item.activeimg').each(function(){if(real_srcset=jQuery(this).attr("data-srcset")){if(!jQuery(this).attr("srcset"))jQuery(this).attr("srcset",real_srcset)}if(real_src=jQuery(this).attr("data-src")){if(!jQuery(this).attr("srcset"))jQuery(this).attr("src",real_src)}});$hide_count=$new_items_count-1;jQuery($carousel).find(".carousel-indicatorsli:gt("+$hide_count+")").addClass("d-none")}jQuery(window).trigger("aui_carousel_multiple")}functionaui_init_carousel_multiple_items(){jQuery(window).on("resize",function(){jQuery('.carousel-multiple-items').each(function(){aui_carousel_maybe_show_multiple_items(this)})});jQuery('.carousel-multPrenota direttamente con albergatore. Riceverai il miglior accordo e servizio.iple-items').each(function(){aui_carousel_maybe_show_multiple_items(this)})}functioninit_n_sub_menus(){jQuery('.nbar-multi-sub-menus').each(function(i,obj){if(jQuery(this).hasClass("has-sub-sub-menus")){returntrue}jQuery(this).addClass('has-sub-sub-menus');jQuery(this).find('.dropdown-menua.dropdown-toggle').on('click',function(e){var$el=jQuery(this);$el.toggleClass('active-dropdown');var$parent=jQuery(this).offsetParent(".dropdown-menu");if(!jQuery(this).next().hasClass('show')){jQuery(this).parents('.dropdown-menu').first().find('.show').removeClass("show")}var$subMenu=jQuery(this).next(".dropdown-menu");$subMenu.toggleClass('show');jQuery(this).parent("li").toggleClass('show');jQuery(this).parents('li.n-item.dropdown.show').on('hidden.bs.dropdown',function(e){jQuery('.dropdown-menu.show').removeClass("show");$el.removeClass('active-dropdown')});if(!$parent.parent().hasClass('nbar-n')){$el.next().addClass('position-relativeborder-topborder-bottom')}returnfalse})})}functionaui_lightbox_embed($link,ele){ele.preventDefault();jQuery('.aui-carousel-modal').remove();var$modal='';jQuery('body').append($modal);constayeModal=newbootstrap.Modal('.aui-carousel-modal',{});constmyModalEl=document.getElementById('aui-carousel-modal');myModalEl.addEventListener('hidden.bs.modal',event=>{jQuery(".aui-carousel-modaliframe").attr('src','')});$container=jQuery($link).closest('.aui-gallery');$clicked_href=jQuery($link).attr('href');$imes=[];$container.find('.aui-lightbox-ime').each(function(){vara=this;varhref=jQuery(a).attr('href');if(href){$imes.push(href)}});if($imes.length){var$carousel='';if($imes.length>1){$i=0;$carousel+='';$container.find('.aui-lightbox-ime').each(function(){$active=$clicked_href==jQuery(this).attr('href')?'active':'';$carousel+='';$i++});$carousel+=''}$i=0;$carousel+='';$container.find('.aui-lightbox-ime').each(function(){vara=this;varhref=jQuery(a).attr('href');$active=$clicked_href==jQuery(this).attr('href')?'active':'';$carousel+='';varcss_height=window.innerWidth>window.innerHeight?'90vh':'auto';varsrcset=jQuery(a).find('img').attr('srcset');varsizes='';if(srcset){varsources=srcset.split(',').map(s=>{varparts=s.trim().split('');return{width:parseInt(parts[1].replace('w','')),descriptor:parts[1].replace('w','px')}}).sort((a,b)=>b.width-a.width);sizes=sources.map((source,index,arraPrenota direttamente con albergatore. Riceverai il miglior accordo e servizio.y)=>{if(index===0){return`${source.descriptor}`}else{return`(max-width:${source.width-1}px)${array[index-1].descriptor}`}}).reverse().join(',')}varimg=href?jQuery(a).find('img').clone().attr('src',href).attr('sizes',sizes).removeClass().addClass('mx-autod-blockw-automw-100rounded').css('max-height',css_height).get(0).outerHTML:jQuery(a).find('img').clone().removeClass().addClass('mx-autod-blockw-automw-100rounded').css('max-height',css_height).get(0).outerHTML;$carousel+=img;if(jQuery(a).parent().find('.carousel-caption').length){$carousel+=jQuery(a).parent().find('.carousel-caption').clone().removeClass('sr-onlyvisually-hidden').get(0).outerHTML}elseif(jQuery(a).parent().find('.figure-caption').length){$carousel+=jQuery(a).parent().find('.figure-caption').clone().removeClass('sr-onlyvisually-hidden').addClass('carousel-caption').get(0).outerHTML}$carousel+='';$i++});$container.find('.aui-lightbox-iframe').each(function(){vara=this;$active=$clicked_href==jQuery(this).attr('href')?'active':'';$carousel+='';varcss_height=window.innerWidth>window.innerHeight?'95vh':'auto';varurl=jQuery(a).attr('href');variframe='';varimg=iframe;$carousel+=img;$carousel+='';$i++});$carousel+='';if($imes.length>1){$carousel+='';$carousel+='';$carousel+='';$carousel+='';$carousel+=''}$carousel+='';var$close='';jQuery('.aui-carousel-modal.modal-content').html($carousel).prepend($close);ayeModal.show()}}functionaui_init_lightbox_embed(){jQuery('.aui-lightbox-ime,.aui-lightbox-iframe').off('click').on("click",function(ele){aui_lightbox_embed(this,ele)})}functionaui_init_modal_iframe(){jQuery('.aui-has-embed,[data-aui-embed="iframe"]').each(function(e){if(!jQuery(this).hasClass('aui-modal-iframed')&&jQuery(this).data('embed-url')){jQuery(this).addClass('aui-modal-iframed');jQuery(this).on("click",function(e1){aui_modal_iframe('',jQuery(this).data('embed-url'),'',true,'','modal-lg','aui-modal-iframep-0',true);returnfalse})}})}$aui_doing_toast=false;functionaui_toast($id,$type,$title,$title_small,$body,$time,$can_close){if($aui_doing_toast){setTimeout(function(){aui_toast($id,$type,$title,$title_small,$body,$time,$can_close)},500);return}$aui_doing_toast=true;if($can_close==null){$can_close=false}if($time==''||$time==null){$time=3000}if(document.getElementById($id)){jQuery('#'+$id).toast('show');setTimeout(function(){$aui_doing_toast=false},500);return}varuniqid=Date.now();if($id){uniqid=$id}$op="";$tClass='';$thClass='';$icon="";if($type=='success'){$op="opacity:.92;";$tClass='alertbg-successw-auto';$thClass='bg-transparentborder-0text-white';$icon=""}elseif($type=='error'||$type=='danger'){$op="opacity:.92;";$tClass='alertbg-dangerw-auto';$thClass='bg-transparentborder-0text-white';$icon=""}elseif($type=='info'){$op="opacity:.92;";$tClass='alertbg-infow-auto';$thClass='bg-transparentborder-0text-white';$icon=""}elseif($type=='warning'){$op="opacity:.92;";$tClass='alertbg-warningw-auto';$thClass='bg-transparentborder-0text-dark';$icon=""}if(!document.getElementById("aui-toasts")){jQuery('body').append('')}$toast='';if($type||$title||$title_small){$toast+='';if($icon){$toast+=$icon}if($title){$toast+=''+$title+''}if($title_small){$toast+=''+$title_small+''}if($can_close){$toast+=''}$toast+=''}if($body){$toast+=''+$body+''}$toast+='';jQuery('.aui-toast-bottom-right').prepend($toast);jQuery('#'+uniqid).toast('show');setTimeout(function(){$aui_doing_toast=false},500)}functionaui_init_counters(){constanimNum=(EL)=>{if(EL._isAnimated)return;EL._isAnimated=true;letend=EL.dataset.auiend;letstart=EL.dataset.auistart;letduration=EL.dataset.auiduration?EL.dataset.auiduration:2000;letseperator=EL.dataset.auisep?EL.dataset.auisep:'';jQuery(EL).prop('Counter',start).animate({Counter:end},{duration:Math.abs(duration),easing:'swing',step:function(now){consttext=seperator?(Math.ceil(now)).toLocaleString('en-US'):Math.ceil(now);consthtml=seperator?text.split(",").map(n=>`${n}`).join(","):text;if(seperator&&seperator!=','){html.replace(',',seperator)}jQuery(this).html(html)}})};constinViewport=(entries,observer)=>{entries.forEach(entry=>{if(entry.isIntersecting)animNum(entry.target)})};jQuery("[data-auicounter]").each((i,EL)=>{constobserver=newIntersectionObserver(inViewport);observer.observe(EL)})}functionaui_init(){aui_init_counters();init_n_sub_menus();aui_init_tooltips();aui_init_select2();aui_init_flatpickr();aui_init_iconpicker();aui_init_greedy_n();aui_time_o('timeo');aui_init_carousel_multiple_items();aui_init_lightbox_embed();aui_init_modal_iframe()}jQuery(window).on("load",function(){aui_init()});jQuery(function($){varua=nigator.userent.toLowerCase();varisiOS=ua.match(/(iphone|ipod|ipad)/);if(isiOS){varpS=0;pM=parseFloat($('body').css('marginTop'));$(document).on('show.bs.modal',function(){pS=window.scrollY;$('body').css({marginTop:-pS,overflow:'hidden',position:'fixed',})}).on('hidden.bs.modal',function(){$('body').css({marginTop:pM,overflow:'visible',position:'inherit',});window.scrollTo(0,pS)})}});varaui_confirm=function(messe,okButtonText,cancelButtonText,isDelete,large){okButtonText=okButtonText||'Yes';cancelButtonText=cancelButtonText||'Cancel';messe=messe||'Areyousure?';sizeClass=large?'':'modal-sm';btnClass=isDelete?'btn-danger':'btn-primary';deferred=jQuery.Deferred();var$body="";$body+=""+messe+"";$body+="";$body+=""+cancelButtonText+"";$body+=""+okButtonText+"";$body+="";$modal=aui_modal('',$body,'',false,'',sizeClass);returndeferred.promise()};functionaui_flip_color_scheme_on_scroll($value,$iframe){if(!$value)$value=window.scrollY;varnbar=$iframe?$iframe.querySelector('.color-scheme-flip-on-scroll'):document.querySelector('.color-scheme-flip-on-scroll');if(nbar==null)return;letcs_original=nbar.dataset.cso;letcs_scroll=nbar.dataset.css;if(!cs_scroll&&!cs_original){if(nbar.classList.contains('nbar-light')){cs_original='nbar-light';cs_scroll='nbar-dark'}elseif(nbar.classList.contains('nbar-dark')){cs_original='nbar-dark';cs_scroll='nbar-light'}nbar.dataset.cso=cs_originalnbar.dataset.css=cs_scroll}if($value>0||nbar.classList.contains('n-menu-open')){nbar.classList.remove(cs_original);nbar.classList.add(cs_scroll)}else{nbar.classList.remove(cs_scroll);nbar.classList.add(cs_original)}}window.onscroll=function(){aui_set_data_scroll();aui_flip_color_scheme_on_scroll()};functionaui_set_data_scroll(){document.documentElement.dataset.scroll=window.scrollY}aui_set_data_scroll();aui_flip_color_scheme_on_scroll();/*]]>*//**//*0){ $_distance.append(''); $btn.removeClass('btn-secondary').addClass('btn-primary'); jQuery('.-gd-icon',$btn).addClass('d-none'); jQuery('.-gd-range',$btn).removeClass('d-none').text(dist+''+unit).attr('title',title); }else{ $_distance.append(''); $btn.removeClass('btn-primary').addClass('btn-secondary'); jQuery('.-gd-icon',$btn).removeClass('d-none'); jQuery('.-gd-range',$btn).addClass('d-none'); } if($_distance.closest('form').find('[name="snear"]').val()){ jQuery('[name="dist"]',$_distance).trigger('change'); } geodir_popover_show_distance($_distance.closest('form'),dist,unit); } }); jQuery(document).on('input','.geodir-distance-range',function(){ var$cont=jQuery(this).closest('.geodir-popover-content'),$_distance=jQuery('#'+$cont.attr('data-'+bsDash+'container')); geodir_popover_show_distance($_distance.closest('form'),parseInt(jQuery(this).val())); }); jQuery('body').on('click',function(e){ if(e&&!e.isTrigger&&jQuery('.geodir-distance-popover[aria-describedby]').length){ jQuery('.geodir-distance-popover[aria-describedby]').each(function(){ if(!jQuery(this).is(e.target)&&jQuery(this).has(e.target).length===0&&jQuery('.popover').has(e.target).length===0){ jQuery(this).popover('hide'); } }); } }); jQuery("body").on("geodir_setup_search_form",function($_form){if(typeofaui_cf_field_init_rules==="function"){setTimeout(function(){aui_cf_field_init_rules(jQuery),100})}}); });functiongeodir_distance_popover_trigger(){ if(!jQuery('.geodir-distance-popover').length){ return; } varbsDash='bs-'; jQuery('.geodir-distance-popover').popover({ html:true, placement:'top', sanitize:false, customClass:'geodir-popover', template:'' }).on('hidden.bs.popover',function(e){ vardist=parseInt(jQuery(this).closest('.gd-search-field-distance').find('[name="dist"]').val()); varunit=jQuery(this).closest('.gd-search-field-distance').find('[name="_unit"]').val(); varcontent=jQuery(this).attr('data-'+bsDash+'content'); content=content.replace('geodir-unit-miactive"','geodir-unit-mi"'); content=content.replace('geodir-unit-kmactive"','geodir-unit-km"'); content=content.replace("checked='checked'",''); content=content.replace('checked="checked"',''); content=content.replace('geodir-drange-values','geodir-drange-valuesd-none'); content=content.replace('d-noned-none','d-none'); content=content.replace('value="'+unit+'"','value="'+unit+'"checked="checked"'); content=content.replace('geodir-unit-'+unit+'"','geodir-unit-'+unit+'active"'); content=content.replace('value="'+jQuery(this).attr('data-value')+'"','value="'+dist+'"'); jQuery(this).attr('data-'+bsDash+'content',content); jQuery(this).attr('data-value',dist); }).on('shown.bs.popover',function(e){ geodir_popover_show_distance(jQuery(this).closest('form')); });}functiongeodir_popover_show_distance($form,dist,unit){ if(!$form){ $form=jQuer('body'); } if(typeofdist=='undefined'){ dist=parseInt(jQuery('[name="dist"]',$form).val()); } jQuery('.geodir-drange-dist').text(dist); if(typeofunit=='undefined'){ unit=jQuery('[name="_unit"]',$form).val(); if(unit&&jQuery('.btn.geodir-unit-'+unit,$form).length&&!jQuery('.btn.geodir-unit-'+unit,$form).hasClass('active')){ jQuery('.geodir-units-wrap.geodir-distance-trigger',$form).removeAttr('checked'); jQuery('.geodir-units-wrap.geodir-distance-trigger[value="'+unit+'"]',$form).attr('checked','checked'); jQuery('.geodir-units-wrap.btn',$form).removeClass('active'); jQuery('.btn.geodir-unit-'+unit,$form).addClass('active'); } } if(unit){ jQuery('.geodir-drange-unit').text(unit); } if(dist>0){ if(jQuery('.geodir-drange-values').hasClass('d-none')){ jQuery('.geodir-drange-values').removeClass('d-none'); } }else{ if(!jQuery('.geodir-drange-values').hasClass('d-none')){ jQuery('.geodir-drange-values').addClass('d-none'); } }}functiongeodir_search_setup_advance_search(){ jQuery('.geodir-search-container.geodir-advance-search-searched').each(function(){ var$el=this; if(jQuery($el).attr('data-show-adv')=='search'){ jQuery('.geodir-show-filters',$el).trigger('click'); } }); jQuery('.geodir-more-filters','.geodir-filter-container').each(function(){ var$cont=this; var$form=jQuery($cont).closest('form'); var$adv_show=jQuery($form).closest('.geodir-search-container').attr('data-show-adv'); if($adv_show=='always'&&typeofjQuery('.geodir-show-filters',$form).html()!='undefined'){ jQuery('.geodir-show-filters',$form).remove(); if(!jQuery('.geodir-more-filters',$form).is(":visible")){ jQuery('.geodir-more-filters',$form).slideToggle(500); } } }); geodir_distance_popover_trigger(); }functiongeodir_search_setup_searched_filters(){ jQuery(document).on('click','.gd-adv-search-labels.gd-adv-search-label',function(e){ if(!jQuery(this).hasClass('geodir-clear-filters')){ var$this=jQuery(this),$form,name,to_name; name=$this.data('name'); to_name=$this.data('names'); if((typeofname!='undefined'&&name)||$this.hasClass('gd-adv-search-near')){ jQuery('.geodir-search-containerform').each(function(){ $form=jQuery(this); if($this.hasClass('gd-adv-search-near')){ name='snear'; jQuery('.sgeo_lat,.sgeo_lon,.geodir-location-search-type',$form).val(''); jQuery('.geodir-location-search-type',$form).attr('name',''); } if(jQuery('[name="'+name+'"]',$form).closest('.gd-search-has-date').length){ jQuery('[name="'+name+'"]',$form).closest('.gd-search-has-date').find('input').each(function(){ geodir_search_deselect(jQuery(this)); }); }else{ geodir_search_deselect(jQuery('[name="'+name+'"]',$form)); if(typeofto_name!='undefined'&&to_name){ geodir_search_deselect(jQuery('[name="'+to_name+'"]',$form)); } if((name=='snear'||name=='dist')&&jQuery('.geodir-distance-popover',$form).length){ if(jQuery('[name="_unit"]',$form).length){ jQuery('[name="dist"]',$form).remove(); var$btn=jQuery('.geodir-distance-show',$form); $btn.removeClass('btn-primary').addClass('btn-secondary'); jQuery('.-gd-icon',$btn).removeClass('d-none'); jQuery('.-gd-range',$btn).addClass('d-none'); } } } }); if(!window.isClearFilters){ $form=jQuery('.geodir-search-containerform'); if($form.length>1){$form=jQuery('.geodir-current-form:visible').length?jQuery('.geodir-current-form:visible:first'):jQuery('.geodir-search-container:visible:firstform');} geodir_search_trigger_submit($form); } } $this.remove(); } });}functiongeodir_search_refresh_open_now_times(){ jQuery('.geodir-search-containerselect[name="sopen_now"]').each(function(){ geodir_search_refresh_open_now_time(jQuery(this)); });}functiongeodir_search_refresh_open_now_time($this){ var$option=$this.find('option[value="now"]'),label,value,d,date_now,time,$label,open_now_format=geodir_search_params.open_now_format; if($option.length&&open_now_format){ if($option.data('bkp-text')){ label=$option.data('bkp-text'); }else{ label=$option.text(); $option.attr('data-bkp-text',label); } d=newDate(); date_now=d.getFullYear()+'-'+(("0"+(d.getMonth()+1)).slice(-2))+'-'+(("0"+(d.getDate())).slice(-2))+'T'+(("0"+(d.getHours())).slice(-2))+':'+(("0"+(d.getMinutes())).slice(-2))+':'+(("0"+(d.getSeconds())).slice(-2)); time=geodir_search_format_time(d); open_now=geodir_search_params.open_now_format; open_now=open_now.replace("{label}",label); open_now=open_now.replace("{time}",time); $option.text(open_now); $option.closest('select').data('date-now',date_now); /*Searchedlabel*/ $label=jQuery('.gd-adv-search-open_now.gd-adv-search-label-t'); if(jQuery('.gd-adv-search-open_now').length&&jQuery('.gd-adv-search-open_now').data('value')=='now'){ if($label.data('bkp-text')){ label=$label.data('bkp-text'); }else{ label=$label.text(); $label.attr('data-bkp-text',label); } open_now=geodir_search_params.open_now_format; open_now=open_now.replace("{label}",label); open_now=open_now.replace("{time}",time); $label.text(open_now); } }}functiongeodir_search_format_time(d){ varformat=geodir_search_params.time_format,am_pm=eval(geodir_search_params.am_pm),hours,aL,aU; hours=d.getHours(); if(hours12?hours-12:hours; aL=2; aU=3; } time=format.replace("g",hours); time=time.replace("G",(d.getHours())); time=time.replace("h",("0"+hours).slice(-2)); time=time.replace("H",("0"+(d.getHours())).slice(-2)); time=time.replace("i",("0"+(d.getMinutes())).slice(-2)); time=time.replace("s",''); time=time.replace("a",am_pm[aL]); time=time.replace("A",am_pm[aU]); returntime;}functiongeodir_search_deselect(el){ varfType=jQuery(el).prop('type'); switch(fType){ case'checkbox': case'radio': jQuery(el).prop('checked',false); jQuery(el).trigger('gdclear'); break; default: jQuery(el).val(''); jQuery(el).trigger('gdclear'); break; }}functiongeodir_search_trigger_submit($form){ if(!$form){ $form=jQuery('.geodir-current-form').length?jQuery('.geodir-current-form'):jQuery('form[name="geodir-listing-search"]'); } if($form.data('show')=='advanced'){ if(jQuery('form.geodir-search-show-all:visible').length){ $form=jQuery('form.geodir-search-show-all'); }elseif(jQuery('form.geodir-search-show-main:visible').length){ $form=jQuery('form.geodir-search-show-main'); }elseif(jQuery('[name="geodir_search"]').closest('form:visible').length){ $form=jQuery('[name="geodir_search"]').closest('form'); } } geodir_click_search($form.find('.geodir_submit_search'));}functiongeodir_search_update_button(){ return'UpdateResults';}varaui_cf_field_rules=[],aui_cf_field_key_rules={},aui_cf_field_default_values={};jQuery(function($){aui_cf_field_init_rules($)});functionaui_cf_field_init_rules($){if(!$('[data-has-rule]').length){return}$('input.select2-search__field').attr('data-ignore-rule','');$('[data-rule-key]').on('changekeypresskeyupgdclear','input,textarea',function(){if(!$(this).hasClass('select2-search__field')){aui_cf_field_apply_rules($(this))}});$('[data-rule-key]').on('changechange.select2gdclear','select',function(){aui_cf_field_apply_rules($(this))});aui_cf_field_setup_rules($)}functionaui_cf_field_setup_rules($){varaui_cf_field_keys=[];$('[data-rule-key]').each(function(){varkey=$(this).data('rule-key'),irule=parseInt($(this).data('has-rule'));if(key){aui_cf_field_keys.push(key)}varparse_conds={};if($(this).data('rule-fie-0')){$(this).find('input,select,textarea').each(function(){if($(this).attr('required')||$(this).attr('oninvalid')){$(this).addClass('aui-cf-req');if($(this).attr('required')){$(this).attr('data-rule-req',true)}if($(this).attr('oninvalid')){$(this).attr('data-rule-oninvalid',$(this).attr('oninvalid'))}}});for(vari=0;iparseInt(condition.value)){$keys[condition.key][index]=true}else{$keys[condition.key][index]=false}}elseif(condition.condition==='lessthan'){varfield_value=(Array.isArray(current_value)&¤t_value.length===1)?current_value[0]:current_value;if(jQuery.isNumeric(condition.value)&&parseInt(field_value)=0)||(Array.isArray(current_value)&&aui_cf_field_in_array(svalue,current_value)))){found=true}}if(found){$keys[condition.key][index]=true}else{$keys[condition.key][index]=false}break;case'checkbox':if(current_value&&((!Array.isArray(current_value)&¤t_value.indexOf(condition.value)>=0)||(Array.isArray(current_value)&&aui_cf_field_in_array(condition.value,current_value)))){$keys[condition.key][index]=true}else{$keys[condition.key][index]=false}break;default:if(typeof$keys[condition.key][index]==='undefined'){if(current_value&¤t_value.indexOf(condition.value)>=0&&aui_cf_field_in_array(current_value,$keys_values[condition.key],false,true)){$keys[condition.key][index]=true}else{$keys[condition.key][index]=false}}break}}});jQuery.each($keys,function(index,field){if(aui_cf_field_in_array(true,field)){aui_cf_field_apply_action($el,$key_rules[index],true)}else{aui_cf_field_apply_action($el,$key_rules[index],false)}});if($keys.length){$el.trigger('aui_cf_field_on_change')}}functionaui_cf_field_get_element($el){varel=$el.find('input:not("[data-ignore-rule]"),textarea,select'),type=aui_cf_field_get_type($el);if(type&&window._aui_cf_field_elements&&typeofwindow._aui_cf_field_elements=='object'&&typeofwindow._aui_cf_field_elements[type]!='undefined'){el=window._aui_cf_field_elements[type]}returnel}functionaui_cf_field_get_type($el){return$el.data('rule-type')}functionaui_cf_field_get_value($el){varcurrent_value=$el.val();if($el.is(':checkbox')){current_value='';if($el.parents('[data-rule-key]').find('input:checked').length>1){$el.parents('[data-rule-key]').find('input:checked').each(function(){current_value=current_value+jQuery(this).val()+''})}else{if($el.parents('[data-rule-key]').find('input:checked').length>=1){current_value=$el.parents('[data-rule-key]').find('input:checked').val()}}}if($el.is(':radio')){current_value=$el.parents('[data-rule-key]').find('input[type=radio]:checked').val()}returncurrent_value}functionaui_cf_field_get_default_value($el){varvalue='',type=aui_cf_field_get_type($el);switch(type){case'text':case'number':case'date':case'textarea':case'select':value=$el.find('input:text,input[type="number"],textarea,select').val();break;case'phone':case'email':case'color':case'url':case'hidden':case'password':case'file':value=$el.find('input[type="'+type+'"]').val();break;case'multiselect':value=$el.find('select').val();break;case'radio':if($el.find('input[type="radio"]:checked').length>=1){value=$el.find('input[type="radio"]:checked').val()}break;case'checkbox':if($el.find('input[type="checkbox"]:checked').length>=1){if($el.find('input[type="checkbox"]:checked').length>1){varvalues=[];values.push(value);$el.find('input[type="checkbox"]:checked').each(function(){values.push(jQuery(this).val())});value=values}else{value=$el.find('input[type="checkbox"]:checked').val()}}break;default:if(window._aui_cf_field_default_values&&typeofwindow._aui_cf_field_default_values=='object'&&typeofwindow._aui_cf_field_default_values[type]!='undefined'){value=window._aui_cf_field_default_values[type]}break}return{type:type,value:value}}functionaui_cf_field_reset_default_value($el){vartype=aui_cf_field_get_type($el),key=$el.data('rule-key'),field=aui_cf_field_default_values[key];switch(type){case'text':case'number':case'date':case'textarea':$el.find('input:text,input[type="number"],textarea').val(field.value);break;case'phone':case'email':case'color':case'url':case'hidden':case'password':case'file':$el.find('input[type="'+type+'"]').val(field.value);break;case'select':$el.find('select').find('option').prop('selected',false);$el.find('select').val(field.value);$el.find('select').trigger('change');break;case'multiselect':$el.find('select').find('option').prop('selected',false);if((typeoffield.value==='object'||typeoffield.value==='array')&&!field.value.length&&$el.find('selectoption:first').text()==''){$el.find('selectoption:first').remove()}if(typeoffield.value==='string'){$el.find('select').val(field.value)}else{jQuery.each(field.value,function(i,v){$el.find('select').find('option[value="'+v+'"]').attr('selected',true)})}$el.find('select').trigger('change');break;case'checkbox':if($el.find('input[type="checkbox"]:checked').length>=1){$el.find('input[type="checkbox"]:checked').prop('checked',false);if(Array.isArray(field.value)){jQuery.each(field.value,function(i,v){$el.find('input[type="checkbox"][value="'+v+'"]').attr('checked',true)})}else{$el.find('input[type="checkbox"][value="'+field.value+'"]').attr('checked',true)}}break;case'radio':if($el.find('input[type="radio"]:checked').length>=1){setTimeout(function(){$el.find('input[type="radio"]:checked').prop('checked',false);$el.find('input[type="radio"][value="'+field.value+'"]').attr('checked',true)},100)}break;default:jQuery(document.body).trigger('aui_cf_field_reset_default_value',type,$el,field);break}if(!$el.hasClass('aui-cf-field-has-changed')){varel=aui_cf_field_get_element($el);if(type==='radio'||type==='checkbox'){el=el.find(':checked')}if(el){el.trigger('change');$el.addClass('aui-cf-field-has-changed')}}}functionaui_cf_field_get_children(field_key){varrules=[];jQuery.each(aui_cf_field_rules,function(j,rule){if(rule.field.field===field_key){rules.push(rule.field.rule)}});returnrules}functionaui_cf_field_in_array(find,item,exact,match){varfound=false,key;exact=!!exact;for(keyinitem){if((exact&&item[key]===find)||(!exact&&item[key]==find)||(match&&(typeoffind==='string'||typeoffind==='number')&&(typeofitem[key]==='string'||typeofitem[key]==='number')&&find.length&&find.indexOf(item[key])>=0)){found=true;break}}returnfound}functionaui_cf_field_apply_action($el,rule,isTrue){var$destEl=jQuery('[data-rule-key="'+rule.key+'"]');if(rule.action==='show'&&isTrue){if($destEl.is(':hidden')){aui_cf_field_reset_default_value($destEl)}aui_cf_field_show_element($destEl)}elseif(rule.action==='show'&&!isTrue){aui_cf_field_hide_element($destEl)}elseif(rule.action==='hide'&&isTrue){aui_cf_field_hide_element($destEl)}elseif(rule.action==='hide'&&!isTrue){if($destEl.is(':hidden')){aui_cf_field_reset_default_value($destEl)}aui_cf_field_show_element($destEl)}return$el.removeClass('aui-cf-field-has-changed')}functionaui_cf_field_show_element($el){$el.removeClass('d-none').show();$el.find('.aui-cf-req').each(function(){if(jQuery(this).data('rule-req')){jQuery(this).removeAttr('required').prop('required',true)}if(jQuery(this).data('rule-oninvalid')){jQuery(this).removeAttr('oninvalid').attr('oninvalid',jQuery(this).data('rule-oninvalid'))}});if(window&&window.nigator.userent.indexOf("MSIE")!==-1){$el.css({"visibility":"visible"})}}functionaui_cf_field_hide_element($el){$el.addClass('d-none').hide();$el.find('.aui-cf-req').each(function(){if(jQuery(this).data('rule-req')){jQuery(this).removeAttr('required')}if(jQuery(this).data('rule-oninvalid')){jQuery(this).removeAttr('oninvalid')}});if(window&&window.nigator.userent.indexOf("MSIE")!==-1){$el.css({"visibility":"hidden"})}} /*]]>*//**//**//**//**/varajaxurl="accommodationbutton.com/wp-admin/admin-ajax.php"; .getpaid-price-buttonslabel{ transition:all.3sease-out; text-align:center; padding:10px20px; background-color:#eeeeee; border:1pxsolid#e0e0e0; } .getpaid-price-circleslabel{ padding:04px; -moz-border-radius:50%; -webkit-border-radius:50%; border-radius:50%; } .getpaid-price-circleslabelspan{ display:block; padding:50%; margin:-3em-50%0; position:relative; top:1.5em; border:1emsolidtransparent; white-space:nowrap; } .getpaid-price-buttonsinput[type="radio"]{ visibility:hidden; height:0; width:0!important; } .getpaid-price-buttonsinput[type="radio"]:checked+label, .getpaid-price-buttonslabel:hover{ color:#fff; background-color:#1e73be; border-color:#1e73be; } .getpaid-public-items-archive-single-item.inner{ box-shadow:01px3pxrgba(0,0,0,0.12),01px2pxrgba(0,0,0,0.24); } .getpaid-public-items-archive-single-item:hover.inner{ box-shadow:01px4pxrgba(0,0,0,0.15),01px3pxrgba(0,0,0,0.30); } .wp-block-getpaid-public-items-getpaid-public-items-loop.item-name{ font-size:1.3rem; } .getpaid-subscription-item-actions{ color:#ddd; font-size:13px; padding:2px00; position:relative; left:-9999em; } .getpaid-subscriptions-table-row:hover.getpaid-subscription-item-actions{ position:static; } .getpaid-subscriptionstable{ font-size:0.9em; table-layout:fixed; } .getpaid-subscriptions-table-column-subscription{ font-weight:500; } .getpaid-subscriptions-table-rowspan.label{ font-weight:500; } .getpaid-subscriptions.bsui.table-borderedtheadth{ border-bottom-width:1px; } .getpaid-subscriptions.bsui.table-stripedtbodytr:nth-of-type(odd){ background-color:rgb(000/0.01); } .wpinv-pe.bsuia.btn{ text-decoration:none; margin-right:2px; margin-bottom:2px; } .getpaid-cc-card-inner{ max-width:460px; } .getpaid-payment-modal-close{ position:absolute; top:0; right:0; z-index:200; } .getpaid-form-cart-item-price{ min-width:120px!important; } /*FabulousFluidthemefix*/ #primary.getpaid-payment-formp{ float:none!important; } .bsui.is-invalid~.invalid-feedback,.bsui.is-invalid~.invalid-tooltip{ display:block } .bsui.is-invalid{ border-color:#dc3545!important; } .getpaid-file-upload-element{ height:200px; border:3pxdashed#dee2e6; cursor:pointer; } .getpaid-file-upload-element:hover{ border:3pxdashed#; } .getpaid-file-upload-element.getpaid-trying-to-drop{ border:3pxdashed#8bc34a; background:#f1f8e9; } ©2024DirectoryStarterTheme-PoweredbyWordPress. vardefault_location='Philadelphia'; varlatlng; varaddress; vardist=0; varSgeocoder=(typeofgoogle!=='undefined'&&typeofgoogle.maps!=='undefined')?newgoogle.maps.Geocoder():{}; jQuery(function($){ if($('.geodir-listing-searchinput[name="snear"]').length&&!window.geodirMapAllScriptsLoaded){ $('.geodir-listing-searchinput[name="snear"]').each(function(){ if(!window.geodirMapAllScriptsLoaded){ $(this).on('focus',function(e){ /*Loadlazyloadscripts*/ if(!window.geodirMapAllScriptsLoaded&&!window.geodirApiScriptLoading){ $(this).geodirLoadMap({loadJS:true}); jQuery(window).trigger('resize'); } }); } }); } }); functiongeodir_setup_submit_search($form){ jQuery('.geodir_submit_search').off('click');//unbindanyotherclickevents jQuery('.geodir_submit_search').on("click",function(e){ e.preventDefault(); vars=''; var$form=jQuery(this).closest('form'); if(jQuery("#sdistanceinput[type='radio']:checked").length!=0)dist=jQuery("#sdistanceinput[type='radio']:checked").val(); if(jQuery('.search_text',$form).val()==''||jQuery('.search_text',$form).val()=='Searchfor')jQuery('.search_text',$form).val(s); //Disablelocationbasedsearchfordisabledlocationposttype. if(jQuery('.search_by_post',$form).val()!=''&&typeofgd_cpt_no_location=='function'){ if(gd_cpt_no_location(jQuery('.search_by_post',$form).val())){ jQuery('.snear',$form).remove(); jQuery('.sgeo_lat',$form).remove(); jQuery('.sgeo_lon',$form).remove(); jQuery('select[name="sort_by"]',$form).remove(); jQuery($form).trigger("submit"); return; } } if( dist>0 ||(jQuery('select[name="sort_by"]').val()=='nearest' ||jQuery('select[name="sort_by"]',$form).val()=='farthest') ||(jQuery(".snear",$form).val()!=''&&jQuery(".snear",$form).val()!='Near'&&!jQuery('.geodir-location-search-type',$form).val()) ){ varvNear=jQuery(".snear",$form).val(); /*OSMcan'thandlepostcodewithnospacesowetestforitandaddoneifneeded*/ if(window.gdMaps==='osm'){ var$near_val=vNear; var$is_post_code=$near_val.match("^([A-Za-z][A-Ha-hJ-Yj-y]?[0-9][A-Za-z0-9]??[0-9][A-Za-z]{2}|[Gg][Ii][Rr]?0[Aa]{2})$"); if($is_post_code){ $near_val=$near_val.replace(/.{3}$/,'$&'); jQuery(".snear",$form).val($near_val); } } geodir_setsearch($form); }else{ jQuery(".snear",$form).val(''); jQuery($form).trigger("submit"); } }); //ClearnearsearchGPSforcore if(!jQuery('input.geodir-location-search-type').length&&jQuery('[name="snear"]').length){ jQuery('[name="snear"]').off('keyup'); jQuery('[name="snear"]').on('keyup',function($){ jQuery('.sgeo_lat').val(''); jQuery('.sgeo_lon').val(''); }); } } jQuery(document).ready(function(){ geodir_setup_submit_search(); //setupadvancedsearchformonformajaxload jQuery("body").on("geodir_setup_search_form",function($form){ geodir_setup_submit_search($form); }); }); functiongeodir_setsearch($form){ if((dist>0||(jQuery('select[name="sort_by"]',$form).val()=='nearest'||jQuery('select[name="sort_by"]',$form).val()=='farthest'))&&(jQuery(".snear",$form).val()==''||jQuery(".snear",$form).val()=='Near'))jQuery(".snear",$form).val(default_location); geocodeAddress($form); } functionupdateSearchPosition(latLng,$form){ if(window.gdMaps==='google'){ jQuery('.sgeo_lat').val(latLng.lat()); jQuery('.sgeo_lon').val(latLng.lng()); }elseif(window.gdMaps==='osm'){ jQuery('.sgeo_lat').val(latLng.lat); jQuery('.sgeo_lon').val(latLng.lon); } jQuery($form).trigger("submit");//submitformafterinsertingthelatlongpositions } functiongeocodeAddress($form){ //Callthegeocodefunction Sgeocoder=window.gdMaps=='google'?newgoogle.maps.Geocoder():null; if(jQuery('.snear',$form).val()==''||(jQuery('.sgeo_lat').val()!=''&&jQuery('.sgeo_lon').val()!='')||(jQuery('.snear',$form).val()&&jQuery('.snear',$form).val().match("^In:"))){ if(jQuery('.snear',$form).val()&&jQuery('.snear',$form).val().match("^In:")){ jQuery(".snear",$form).val(''); } jQuery($form).trigger("submit"); }else{ varaddress=jQuery(".snear",$form).val(); if(address&&address.trim()=='Near'){ initialise2(); }elseif(address&&address.trim()=='Near:MyLocation'){ jQuery($form).trigger("submit"); }else{ varsearch_address=address; if(window.gdMaps==='google'){ vargeocodeQueryParams={'address':search_address}; if(geodirIsZipCode(address)){ if(typeofgeocodeQueryParams['componentRestrictions']!='undefined'){ if(typeofgeocodeQueryParams['componentRestrictions']['postalCode']=='undefined'){ geocodeQueryParams['componentRestrictions']['postalCode']=address; } }else{ geocodeQueryParams['componentRestrictions']={'postalCode':address}; } } Sgeocoder.geocode(geocodeQueryParams, function(results,status){ if(status==google.maps.GeocoderStatus.OK){ updateSearchPosition(results[0].geometry.location,$form); }else{ alert("Searchwasnotsuccessfulforthefollowingreason:"+status); } }); }elseif(window.gdMaps==='osm'){ varosmCountryCodes=false; geocodePositionOSM(false,search_address,osmCountryCodes,false, function(geo){ if(typeofgeo!=='undefined'&&geo.lat&&geo.lon){ updateSearchPosition(geo,$form); }else{ alert("Searchwasnotsuccessfulfortherequestedaddress."); } }); }else{ jQuery($form).trigger("submit"); } } } } functiongeodirIsZipCode(string){ if(/^\d+$/.test(string)){ if(string.length>3&&string.length=geodir_search_params.autocomplete_min_chars){ request_url=geodir_params.api_url+""+post_type_slug+"/?search="+search+"&per_pe="+geodir_search_params.autocompleter_max_results; if(geodir_search_params.autocompleter_filter_location&&el&&jQuery(el).closest('form.geodir-listing-search').length){ $form=jQuery(el).closest('form.geodir-listing-search'); lname=jQuery('.geodir-location-search-type',$form).prop('name'); lval=jQuery('.geodir-location-search-type',$form).val(); if(lval&&(lname=='country'||lname=='region'||lname=='city'||lname=='neighbourhood')){ request_url+='&'+lname+'='+lval; } } jQuery.ajax({ type:"GET", url:request_url, dataType:'json', success:function(data){ gdasac_listings=data;gdasac_doing_search--; html=''; gdasac_li_type='listing'; jQuery.each(gdasac_listings,function(index,value){ html=html+gdas_ac_create_li('listing',value); }); jQuery(gdasLe).parent().find("ul.gdasac-listing").empty().append(html); if(html&&gdasac_selected&&!jQuery(el).closest('form.geodir-listing-search').find('.gdas-search-suggestions').is(':visible')){try{jQuery(gdasLe).dropdown('show');}catch(err){console.log(err.messe);}} }, error:function(xhr,textStatus,errorThrown){console.log(errorThrown);} }); }else{jQuery(gdasLe).parent().find("ul.gdasac-listing").empty();}}/*Setthemaxheightforthesuggestiondivsotoneverscrollpastthebottomofthepe.*/functiongdas_ac_resize_suggestions(){setTimeout(function(){if(jQuery(".gd-suggestions-dropdown:visible").length){varoffset=jQuery(".gd-suggestions-dropdown:visible").offset().top;varwindowHeight=jQuery(window).height();varmaxHeight=windowHeight-(offset-jQuery(window).scrollTop());if(jQuery(".gd-suggestions-dropdown:visible").prev().hasClass("gd_search_text")){jQuery(".gd-suggestions-dropdown:visible").css("max-height",windowHeight-40)}else{jQuery(".gd-suggestions-dropdown:visible").css("max-height",maxHeight)}}},50)}functiongdas_ac_init_suggestions($input){setTimeout(function(){gdas_ac_resize_suggestions()},250);jQuery($input).on("keyup",function(e){gdasac_doing_search=3;/*city,region,country*/if(gdasac_keyup_timeout!=null)clearTimeout(gdasac_keyup_timeout);gdasac_keyup_timeout=setTimeout(function(){gdas_ac_maybe_fire_suggestions($input)},500)})}functiongdas_ac_maybe_fire_suggestions(el){gdasac_keyup_timeout=null;if(gdasac_suggestions_with!="terms"){gdas_ac_listings(el)}if(gdasac_suggestions_with!="posts"){gdas_ac_categories(el)}}functiongdas_ac_create_li($type,$data){ varoutput='',history='',$delete=''; var$common_class='list-group-item-actionc-pointerp-0m-0d-flexjustify-content-startalign-items-centertext-muted'; var$common_class_icon='d-flexalign-items-centerjustify-content-centerp-0m-0me-2'; var$common_class_title='dropdown-headerh6p-2m-0bg-light'; var$icon_size='height:38px;width:38px;'; if(gdasac_li_type!=''){if($type=='category'){output+='Categories';}elseif($type=='listing'){output+='Listings';}else{output+=''+$type.charAt(0).toUpperCase()+$type.slice(1)+'';}} gdasac_li_type=''; if($data.history){ history=''; $delete=''; }elseif($type=='category'&&$data.fa_icon){ varicon_color=$data.fa_icon_color?'#fff':''; history=''; }elseif($type=='category'){ history=''; }elseif($type=='listing'&&$data.featured_ime.thumbnail){ history=''; }else{ history=''; } if($type=='category'){ if($data.area){$data.city=$data.area;} output+=''+history+''+$data.name+''+$delete+''; }elseif($type=='listing'){ if($data.area){$data.region=$data.area;} output+=''+history+''+$data.title.rendered+''+$delete+''; } returnoutput;}functiongdasac_click_action($type,$url,$id,$name){if($type=='category'){window.location=$url;}elseif($type=='listing'){window.location=$url}}map_id_arr=[];gdUmarker='';my_location='';lat='';lon='';gdUmarker='';userMarkerActive=false;gdLocationOptions={enableHighAccuracy:true,timeout:5000,maximume:0};jQuery("body").on("map_show",function(event,map_id){map_id_arr.push(map_id);if(lat&&lon){setTimeout(function(map_id){geodir_search_setUserMarker(lat,lon,map_id);},1,map_id);}}); ChangeLocation Findawesomelistingsnearyou! ChangeLocation vargdlmls_selected='';vargdlmls_nearest=[];vargdlmls_country=[];vargdlmls_region=[];vargdlmls_city=[];vargdlmls_neighbourhood=[];vargdlmls_google_sessionToken='';//googlesessiontokenvargdlmls_google_service='';//googleservicevargdlmls_do_not_close=false;vargdlmls_doing_search=0;vargdlmls_doing_nearest=false;vargdlmls_is_search=false;vargdlmls_keyup_timeout=null;jQuery(function(){ //init gdlm_ls_init('.geodir-location-search'); gdlm_ls_init('.snear'); gdlm_is_search_input_location(); //onCPTchange jQuery("body").on("geodir_setup_search_form",function(){ gdlm_ls_init('.geodir-location-search'); gdlm_ls_init('.snear'); gdlm_is_search_input_location(); });});functiongdlm_is_search_input_location(){ /*Checkforonchange*/ jQuery(".snear").on("change",function(){ setTimeout(function(){ if(typeofgeodir_search_params!=='undefined'&&geodir_search_params.autocompleter_filter_location){ jQuery('.gd-search-field-search.gd-suggestions-dropdown').remove(); } var$type=jQuery('.geodir-location-search-type').attr('name'); if($type){ jQuery('.gd-search-field-near').removeClass('in-locationin-neighbourhoodin-cityin-regionin-country').addClass('in-locationin-'+$type); }else{ jQuery('.gd-search-field-near').removeClass('in-locationin-neighbourhoodin-cityin-regionin-country'); } },100); }).on("keyup",function(){ if(!(jQuery(this).val().trim()==geodir_params.txt_near_my_location&&jQuery(this).closest('form').find('.geodir-location-search-type').val()=='me')){ jQuery('.gd-search-field-near').removeClass('in-locationin-neighbourhoodin-cityin-regionin-country'); jQuery('.geodir-location-search-type').val('').attr('name',''); jQuery('.sgeo_lat').val(''); jQuery('.sgeo_lon').val(''); } });}functiongdlm_ls_init($field){ jQuery($field).on("focusin", function(){ gdlmls_selected=this; gdlm_ls_focus_in(this); }).on("focusout", function(){ gdlmls_selected=''; gdlm_ls_focus_out(this); }); //windowresizetasks jQuery(window).on("resize",function(){ gdls_ls_resize_suggestions(); });}functiongdlm_ls_focus_in($input){ if(jQuery($input).parent().find(".gdlm-location-suggestions").length){ gdlm_ls_current_location_suggestion($input); }else{ jQuery($input).after(""+ ""+ ""+ ""+ ""+ ""+ ""+ ""); gdlm_ls_init_suggestions($input); gdlm_ls_current_location_suggestion($input); } //resize gdls_ls_resize_suggestions(); //setifissearchnear if(jQuery('.gdlm-location-suggestions:visible').prev().hasClass('snear')||jQuery($input).hasClass('snear')){ gdlmls_is_search=true; }else{ gdlmls_is_search=false; }}functiongdlm_ls_focus_out($input){ setTimeout(function(){ _ua=nigator.userent.toLowerCase(); isChrome=/chrome/.test(_ua); isWin10=/windowsnt10.0/.test(_ua); if(!gdlmls_do_not_close){ } },200);}/***Setthemaxheightforthesuggestiondivsotoneverscrollpastthebottomofthepe.*/functiongdls_ls_resize_suggestions(){ setTimeout(function(){ if(jQuery('.gdlm-location-suggestions:visible').length){ varoffset=jQuery('.gdlm-location-suggestions:visible').offset().top; varwindowHeight=jQuery(window).height(); varmaxHeight=windowHeight-(offset-jQuery(window).scrollTop()); if(jQuery('.gdlm-location-suggestions:visible').prev().hasClass('snear')){ jQuery('.gdlm-location-suggestions:visible').css('max-height',windowHeight-40); }else{ jQuery('.gdlm-location-suggestions:visible').css('max-height',maxHeight); } } },50);}functiongdlm_ls_init_suggestions($input){ setTimeout(function(){ gdls_ls_resize_suggestions(); },250); jQuery($input).off("keypress").on("keypress",function(e){ if(e.keyCode&&e.keyCode==13&&!gdlmls_is_search&&!jQuery($input).parent().find(".gdlm-location-suggestions").hasClass('show')){ jQuery($input).attr('aria-expanded','true').addClass('show');jQuery($input).parent().find(".gdlm-location-suggestions").addClass('show'); } }); jQuery($input).on("keyup",function($input){ gdlmls_doing_search=3;//city,region,country if(gdlmls_keyup_timeout!=null)clearTimeout(gdlmls_keyup_timeout); gdlmls_keyup_timeout=setTimeout(gdlm_ls_maybe_fire_suggestions,500); });}functiongdlm_ls_maybe_fire_suggestions(){ /*Resettimer*/ gdlmls_keyup_timeout=null; /*Dosuggestions*/ gdlm_ls_current_location_suggestion(); _value=gdlmls_selected?jQuery(gdlmls_selected).val().trim():''; _chars=parseInt(geodir_location_params.autocompleter_min_chars); if((!_value||_chars0&&_value&&parseInt(_value.length)>=_chars)&&!(_value==geodir_params.txt_near_my_location&&jQuery(gdlmls_selected).closest("form").find(".geodir-location-search-type").val()=="me")){ gdlm_ls_city_suggestion(); gdlm_ls_region_suggestion(); gdlm_ls_country_suggestion(); }}functiongdlm_ls_maybe_suggest_more(){ if( gdlmls_doing_search==0&& gdlmls_country.length==0&& gdlmls_region.length==0&& gdlmls_city.length==0&& gdlmls_neighbourhood.length==0 ){ $input=jQuery(gdlmls_selected).val(); if($input){ if((typeofgoogle!=='undefined'&&typeofgoogle.maps!=='undefined')){ gdlm_ls_google_suggestions($input); } }else{ jQuery(gdlmls_selected).parent().find("ul.gdlmls-more").empty(); } }}functiongdlm_ls_neighbourhood_suggestion(){ var$search=jQuery(gdlmls_selected).val(); if($search){ jQuery.ajax({ type:"GET", url:geodir_params.api_url+"locations/neighbourhoods/?search="+$search, success:function(data){ gdlmls_neighbourhood=data; gdlmls_doing_search--; gdlm_ls_maybe_suggest_more(); html=''; jQuery.each(gdlmls_neighbourhood,function(index,value){ html=html+gdlm_ls_create_li('neighbourhood',value); }); jQuery(gdlmls_selected).parent().find("ul.gdlmls-neighbourhood").empty().append(html); if(html&&gdlmls_is_search){ geodirLMShowDropdown(gdlmls_selected); } }, error:function(xhr,textStatus,errorThrown){ console.log(errorThrown); } }); }else{ gdlmls_neighbourhood=[]; gdlmls_doing_search--; gdlm_ls_maybe_suggest_more(); jQuery(gdlmls_selected).parent().find("ul.gdlmls-city").empty(); }}functiongdlm_ls_city_suggestion(){ var$search=jQuery(gdlmls_selected).val(); if($search){ jQuery.ajax({ type:"GET", url:geodir_params.api_url+"locations/cities/?search="+$search, success:function(data){ gdlmls_city=data; gdlmls_doing_search--; gdlm_ls_maybe_suggest_more(); html=''; jQuery.each(gdlmls_city,function(index,value){ html=html+gdlm_ls_create_li('city',value); }); jQuery(gdlmls_selected).parent().find("ul.gdlmls-city").empty().append(html); if(html&&gdlmls_is_search){ geodirLMShowDropdown(gdlmls_selected); } }, error:function(xhr,textStatus,errorThrown){ console.log(errorThrown); } }); }else{ gdlmls_city=[]; gdlmls_doing_search--; gdlm_ls_maybe_suggest_more(); jQuery(gdlmls_selected).parent().find("ul.gdlmls-city").empty(); }}functiongdlm_ls_region_suggestion(){ var$search=jQuery(gdlmls_selected).val(); if($search){ jQuery.ajax({ type:"GET", url:geodir_params.api_url+"locations/regions/?search="+$search, success:function(data){ gdlmls_region=data; gdlmls_doing_search--; gdlm_ls_maybe_suggest_more(); html=''; jQuery.each(gdlmls_region,function(index,value){ html=html+gdlm_ls_create_li('region',value); }); jQuery(gdlmls_selected).parent().find("ul.gdlmls-region").empty().append(html); if(html&&gdlmls_is_search){ geodirLMShowDropdown(gdlmls_selected); } }, error:function(xhr,textStatus,errorThrown){ console.log(errorThrown); } }); }else{ gdlmls_region=[]; gdlmls_doing_search--; gdlm_ls_maybe_suggest_more(); jQuery(gdlmls_selected).parent().find("ul.gdlmls-region").empty(); }}functiongdlm_ls_country_suggestion(){ var$search=jQuery(gdlmls_selected).val(); if($search){ jQuery.ajax({ type:"GET", url:geodir_params.api_url+"locations/countries/?search="+$search, success:function(data){ gdlmls_country=data; gdlmls_doing_search--; gdlm_ls_maybe_suggest_more(); html=''; jQuery.each(gdlmls_country,function(index,value){ html=html+gdlm_ls_create_li('country',value); }); jQuery(gdlmls_selected).parent().find("ul.gdlmls-country").empty().append(html); if(html&&gdlmls_is_search){ geodirLMShowDropdown(gdlmls_selected); } }, error:function(xhr,textStatus,errorThrown){ console.log(errorThrown); } }); }else{ gdlmls_country=[]; gdlmls_doing_search--; gdlm_ls_maybe_suggest_more(); jQuery(gdlmls_selected).parent().find("ul.gdlmls-country").empty(); }}functiongdlm_ls_current_location_suggestion(){ jQuery(gdlmls_selected).parent().find("ul.gdlmls-near").empty(); //Nearme jQuery(gdlmls_selected).parent().find("ul.gdlmls-near").empty().append(gdlm_ls_create_li('near',{ type:"near", slug:"me", title:geodir_params.txt_form_my_location })); if(jQuery(gdlmls_selected).val()==''){ var$search_history=JSON.parse(gdlm_ls_get_location_history()); if($search_history){ jQuery.each($search_history,function(index,value){ jQuery(gdlmls_selected).parent().find("ul.gdlmls-near").append(gdlm_ls_create_li(value.type,value)); }); } if(!geodir_location_params.disable_nearest_cities){ //Addnearcitiesfromip gdlm_ls_nearest_cities(); } } console.log(JSON.parse(gdlm_ls_get_location_history()));}functiongdlm_ls_nearest_cities(){ if(!gdlmls_doing_nearest){ gdlmls_doing_nearest=true; jQuery.ajax({ type:"GET", url:geodir_params.api_url+"locations/cities/?orderby=ip", success:function(data){ if(data){ jQuery.each(data,function(index,value){ jQuery(gdlmls_selected).parent().find("ul.gdlmls-near").append(gdlm_ls_create_li('city',value)); }); } gdlmls_doing_nearest=false; }, error:function(xhr,textStatus,errorThrown){ console.log(errorThrown); gdlmls_doing_nearest=false; } }); }}functiongdlm_ls_create_li($type,$data){ varoutput; varhistory=''; var$delete=''; var$common_class='list-group-item-actionc-pointerpx-1py-1m-0d-flexjustify-content-between'; if($data.history){ history=''; $delete=''; }elseif($type=='neighbourhood'||$type=='city'||$type=='region'||$type=='country'){ history=''; } console.log($data); if($type=='neighbourhood'){ if($data.area){$data.city=$data.area;} output=''+history+'In:'+$data.title+','+$data.city+'(Neighbourhood)'+$delete+''; }elseif($type=='city'){ if($data.area){$data.region=$data.area;} output=''+history+'In:'+$data.title+','+$data.region+'(City)'+$delete+''; }elseif($type=='region'){ if($data.area){$data.country=$data.area;} output=''+history+'In:'+$data.title+','+$data.country_title+'(Region)'+$delete+''; }elseif($type=='country'){ output=''+history+'In:'+$data.title+'(Country)'+$delete+''; }elseif($type=='near'){ output='Near:'+$data.title+''; }elseif($type=='near-search'){ output='Near:'+$data.description+''; } returnoutput;}functiongdlm_click_action($type,$title,$area,$country_slug,$region_slug,$city_slug,$hood_slug){ if(gdlmls_is_search){ if($type=='neighbourhood'||$type=='city'||$type=='region'||$type=='country'){ $slug=''; if($type=='neighbourhood'){$slug=$hood_slug;} elseif($type=='city'){$slug=$city_slug;} elseif($type=='region'){$slug=$region_slug;} elseif($type=='country'){$slug=$country_slug;} gdlm_search_fill_location($type,$slug,$title); }elseif($type=='near-search'){ gdlm_search_fill_location($type,'',$title); }elseif($type=='near'){ gd_get_user_position(gdlm_search_near_me); } }else{ if($type=='neighbourhood'||$type=='city'||$type=='region'||$type=='country'){ gdlm_go_location($type,$title,$area,$country_slug,$region_slug,$city_slug,$hood_slug); }elseif($type=='near-search'){ gdlm_go_search($title); }elseif($type=='near'){ gd_get_user_position(gdlm_ls_near_me); } } setTimeout(function(){ _ua=nigator.userent.toLowerCase(); isChrome=/chrome/.test(_ua); isWin10=/windowsnt10.0/.test(_ua); if(isChrome&&isWin10){ jQuery(".gdlm-location-suggestions").hide(); } },200);}functiongdlm_ls_near_me($lat,$lon){ window.location=geodir_params.location_base_url+"near/me/"+$lat+","+$lon+"/";}functiongdlm_ls_near_gps($lat,$lon){ window.location=geodir_params.location_base_url+"near/gps/"+$lat+","+$lon+"/";}functiongdlm_search_near_me($lat,$lon){ gdlm_search_fill_location('near','me',"Near:"+geodir_params.txt_form_my_location,$lat,$lon)}functiongdlm_search_fill_location($type,$slug,$title,$lat,$lon){ if($type=='near'){ }elseif($type=='near-search'){ $type=''; }else{ vartxtType; if($type=='country'){ txtType='(Country)'; }elseif($type=='region'){ txtType='(Region)'; }elseif($type=='city'){ txtType='(City)'; }elseif($type=='neighbourhood'){ txtType='(Neighbourhood)'; }else{ txtType="("+$type+")"; } $title="In:"+$title+""+txtType; } jQuery('.geodir-location-search-type').val($slug).attr('name',$type); jQuery('.sgeo_lat').val($lat); jQuery('.sgeo_lon').val($lon); jQuery('.snear').val($title).trigger('change');//firechangeeventsowecancheckifweneedtoaddin-locationclass}functiongdlm_go_search($text){ if(window.gdMaps==='google'){ vargeocoder=newgoogle.maps.Geocoder(); geocoder.geocode({'address':$text}, function(results,status){ if(status=='OK'){// console.log(results); $lat=results[0].geometry.location.lat(); $lon=results[0].geometry.location.lng(); gdlm_ls_near_gps($lat,$lon); }else{ alert("Searchwasnotsuccessfulforthefollowingreason:"+status); } }); }elseif(window.gdMaps==='osm'){ geocodePositionOSM(false,$text,false,false, function(geo){ if(typeofgeo!=='undefined'&&geo.lat&&geo.lon){ console.log(results); }else{ alert("Searchwasnotsuccessfulfortherequestedaddress."); } }); }}functiongdlm_ls_search_location($type,$term){ jQuery.ajax({ type:"GET", url:geodir_params.api_url+$type+"/?search="+$term, success:function(data){ console.log(data); returndata; //jQuery('#'+map_canvas_var+'_loading_div').hide(); //parse_marker_jason(data,map_canvas_var); }, error:function(xhr,textStatus,errorThrown){ console.log(errorThrown); } });}functiongdlm_go_location($type,$title,$area,$country_slug,$region_slug,$city_slug,$hood_slug){ //sesearchhistorybeforeredirect gdlm_ls_set_location_history($type,$title,$area,$country_slug,$region_slug,$city_slug,$hood_slug); window.location=gdlm_ls_location_url($country_slug,$region_slug,$city_slug,$hood_slug); //console.log(gdlm_ls_location_url($country_slug,$region_slug,$city_slug,$hood_slug));}functiongdlm_ls_location_url($country_slug,$region_slug,$city_slug,$hood_slug){ //$url=geodir_params.location_url.slice(0,-1);//getlocationurlwithouttheendingslash $url=geodir_params.location_base_url;//getlocationurlwithouttheendingslash varshow_country=1; varshow_region=1; varshow_city=1; varshow_hood=0; if(show_country&&$country_slug){ $url+=""+$country_slug+"/"; } if(show_region&&$region_slug){ $url+=""+$region_slug+"/"; } if(show_city&&$city_slug){ $url+=""+$city_slug+"/"; } if(show_hood&&$hood_slug){ $url+=""+$hood_slug+"/"; } return$url;}functiongdlm_ls_get_location_history(){ if(geodir_is_localstore()===true){ returngdlm_ls_history=localStore.getItem("gdlm_ls_history"); }else{ return''; }}functiongdlm_ls_del_location_history($slug){ gdlmls_do_not_close=true; if(geodir_is_localstore()===true){ gdlm_ls_history=JSON.parse(localStore.getItem("gdlm_ls_history")); varfound=''; console.log(gdlm_ls_history); jQuery.each(gdlm_ls_history,function(index,value){ if($slug&&$slug==value.slug){ //itsalreadyinthelistsobail. //gdlm_ls_history.splice(index,1); found=index; } }); if(found!==''){ gdlm_ls_history.splice(found,1); //storetheuserselection localStore.setItem("gdlm_ls_history",JSON.stringify(gdlm_ls_history)); } } setTimeout(function(){gdlmls_do_not_close=false;},200);}functiongdlm_ls_set_location_history($type,$title,$area,$country_slug,$region_slug,$city_slug,$hood_slug){ //setasearchedlocation if(geodir_is_localstore()===true){ vargdlm_ls_history=localStore.getItem("gdlm_ls_history"); var$exists=false; if(!gdlm_ls_history||gdlm_ls_history===undefined){ gdlm_ls_history=[] }else{ gdlm_ls_history=JSON.parse(gdlm_ls_history); jQuery.each(gdlm_ls_history,function(index,value){ console.log(value); if(value.type==$type&&value.title==$title){ //itsalreadyinthelistsobail. $exists=true; } }); } if(!$exists){ $slug=$city_slug; if($type=='neighbourhood'){ $slug=$hood_slug; }if($type=='city'){ $slug=$city_slug; }elseif($type=='region'){ $slug=$region_slug; }elseif($type=='country'){ $slug=$country_slug; } var$location={ history:true,//setitashistorical type:$type, title:$title, country_slug:$country_slug, region_slug:$region_slug, city_slug:$city_slug, hood_slug:$hood_slug, slug:$slug, area:$area }; console.log(gdlm_ls_history); console.log($location); gdlm_ls_history.unshift($location); //gdlm_ls_history=$location; //onlykeeplatest5searches if(gdlm_ls_history.length>5){ gdlm_ls_history.pop(); } } //storetheuserselection localStore.setItem("gdlm_ls_history",JSON.stringify(gdlm_ls_history)); }}functiongdlm_ls_google_suggestions($search){ //Createanewsessiontoken. if(!gdlmls_google_sessionToken){ gdlmls_google_sessionToken=newgoogle.maps.places.AutocompleteSessionToken(); } //displayfunction vardisplaySuggestions=function(predictions,status){ if(status!=google.maps.places.PlacesServiceStatus.OK){ return; } console.log(predictions); html=''; predictions.forEach(function(prediction){ html=html+gdlm_ls_create_li('near-search',prediction); }); jQuery(gdlmls_selected).parent().find("ul.gdlmls-more").empty().append(html); if(html&&gdlmls_is_search){ geodirLMShowDropdown(gdlmls_selected); } }; if(!gdlmls_google_service){ gdlmls_google_service=newgoogle.maps.places.AutocompleteService(); } gdlmls_google_service.getPlacePredictions({input:$search,sessionToken:gdlmls_google_sessionToken,types:['geocode']},displaySuggestions);}functiongdlm_ls_slashit(str){ if(str){ str=str.replace(/'/g,"\\'"); } returnstr;}/***Openthelocationswitcher*/functiongeodir_lm_setup_switcher_trigger(){ varno_show=false; //Clearthelocationandredirecttothebaselocationpe jQuery(".gdlmls-menu-icon").on("click",function(event){ no_show=true; event.preventDefault(); window.location=geodir_params.location_base_url; }); //detectthemenuitemlocationswitcherclick jQuery('a[href$="#location-switcher"]').on("click",function(event){ //preventthehashbeingaddedtotheurl event.preventDefault(); //onlyfireiftheclickisnottheclearlocationbutton. if(!no_show){ jQuery('#gdlm-switcher').modal('show').on('shown.bs.modal',function(e){ jQuery('.modal.geodir-location-search').trigger("focus").trigger("click"); //secondopenmightnottriggerdropdownsowecheck. setTimeout(function(){ if(jQuery('.modal.geodir-location-search').attr('aria-expanded')=='false'){ jQuery('.modal.geodir-location-search').dropdown('show'); } },200); }); } });}functiongeodirLMShowDropdown(el){ /*Windows11Edge/Chromedropdownfix*/ varuA=nigator.userent.toLowerCase(); if(nigator.platform.toLowerCase().indexOf('win')!==-1&&uA.indexOf("windowsnt10")!==-1&&(uA.match(/chrome/i)||uA.match(/edge/i))){ jQuery(el).dropdown('show'); setTimeout(function(){ jQuery('.gd-search-field-near.gdlm-location-suggestions').css('display',"").show(); },30); }elseif(jQuery(el).attr('aria-expanded')=='false'){ jQuery(el).dropdown('show'); }}jQuery(document).ready(function(){geodir_lm_setup_switcher_trigger()});/**/