PageSourceSearch

https://www.cityofalbertlea.org/wp-content/plugins/ajax-search-pro/js/min/plugin/optimized/asp-live.min.js

js cityofalbertlea.org collected 2026-10-02 16:29:08 UTC 5,816 bytes, 1 lines download raw bytes

1(function(){"use strict";var h={};(function(){h.d=function(a,i){for(var e in i)h.o(i,e)&&!h.o(a,e)&&Object.defineProperty(a,e,{enumerable:!0,get:i[e]})}})(),function(){h.o=function(a,i){return Object.prototype.hasOwnProperty.call(a,i)}}();var m={};h.d(m,{default:function(){return S}});var d=Object(window.WPD).AjaxSearchPro,s=Object(window.WPD).DoMini;let l=d.helpers;d.plugin.liveLoad=function(a,i,e,r,p){let n=a;if(n==="body"||n==="html")return console.log("Ajax Search Pro: Do not use html or body as the live loader selector."),!1;let t=this;ASP.pageHTML!==""&&t.setLiveLoadCache(ASP.pageHTML,a);function _(f){let o=l.Hooks.applyFilters("asp/live_load/raw_data",f,t),L=new DOMParser,P=L.parseFromString(o,"text/html"),u=s(P);if(t.o.statistics&&t.stat_addKeyword(t.o.id,t.n("text").val()),o!==""&&u.length>0&&u.find(n).length>0){o=o.replace(/&asp_force_reset_pagination=1/gmi,""),o=o.replace(/%26asp_force_reset_pagination%3D1/gmi,""),o=o.replace(/&#038;asp_force_reset_pagination=1/gmi,""),l.isSafari()&&(o=o.replace(/srcset/gmi,"nosrcset")),o=l.Hooks.applyFilters("asp_live_load_html",o,t.o.id,t.o.iid),u=s(L.parseFromString(o,"text/html"));let g=u.find(n).get(0);g=l.Hooks.applyFilters("asp/live_load/replacement_node",g,t,c.get(0),o),g!=null&&c.get(0).parentNode.replaceChild(g,c.get(0)),c=s(n).first(),e&&(document.title=P.title,history.pushState({},null,i)),s(n).first().find(".woocommerce-ordering select.orderby").on("change",function(){s(this).closest("form").length>0&&s(this).closest("form").get(0).submit()}),t.addHighlightString(s(n).find("a")),l.Hooks.applyFilters("asp/live_load/finished",i,t,n,c.get(0)),ASP.initialize(),t.lastSuccesfulSearch=s("form",t.n("searchsettings")).serialize()+t.n("text").val().trim(),t.lastSearchData=o,t.setLiveLoadCache(f,a)}t.n("s").trigger("asp_search_end",[t.o.id,t.o.iid,t.n("text").val(),o],!0,!0),t.gaEvent?.("search_end",{results_count:"unknown"}),t.hideLoader(),c.css("opacity",1),t.searching=!1,t.n("text").val()!==""&&t.n("proclose").css({display:"block"})}e=typeof e>"u"?!0:e,r=typeof r>"u"?!1:r;let v=[".search-content","#content","#Content","div[role=main]","main[role=main]","div.theme-content","div.td-ss-main-content","main.l-content","#primary"];if(n!=="#main"&&v.unshift("#main"),s(n).length<1&&(v.forEach(function(f){if(s(f).length>0)return n=f,!1}),s(n).length<1))return console.log("Ajax Search Pro: The live search selector does not exist on the page."),!1;n=l.Hooks.applyFilters("asp/live_load/selector",n,this);let c=s(n).first();t.searchAbort(),c.css("opacity",.4),i=l.Hooks.applyFilters("asp/live_load/url",i,t,n,c.get(0)),l.Hooks.applyFilters("asp/live_load/start",i,t,n,c.get(0)),!r&&t.n("searchsettings").find("input[name=filters_initial]").val()==="1"&&t.n("text").val()===""?window.WPD.intervalUntilExecute(function(){_(ASP.pageHTML)},function(){return ASP.pageHTML!==""}):typeof p<"u"?_(p.html):(t.searching=!0,t.post=s.fn.ajax({url:i,method:"GET",success:function(f){_(f),t.isAutoP=!1},dataType:"html",fail:function(f){c.css("opacity",1),!f.aborted&&(c.html("This request has failed. Please check your connection."),t.hideLoader(),t.searching=!1,t.n("proclose").css({display:"block"}),t.isAutoP=!1)}}))},d.plugin.getLiveLoadAltSelectors=function(){return[".search-content","#content #posts-container","#content","#Content","div[role=main]","main[role=main]","div.theme-content","div.td-ss-main-content","main#page-content","main.l-content","#primary","#main-content",".main-content",".search section .bde-post-loop",".archive section .bde-post-loop",".search section .bde-post-list",".archive section .bde-post-list"]},d.plugin.usingLiveLoader=function(){const a=this;if(a._usingLiveLoader!==void 0)return a._usingLiveLoader;const i=a.o,e="asp_es_"+i.id,r=this.getLiveLoadAltSelectors().join(",");if(document.getElementsByClassName(e).length)return a._usingLiveLoader=!0;const p=["resPage","wooShop","cptArchive","taxArchive"];return a._usingLiveLoader=p.some(n=>{const t=i[n];return t.useAjax&&(document.querySelector(t.selector)||r&&document.querySelector(r))}),a._usingLiveLoader},d.plugin.getLiveURLbyBaseLocation=function(a){let i=this,e="asp_ls="+l.nicePhrase(i.n("text").val()),r="&";a.indexOf("?")===-1&&(r="?");
1let p=a+r+e+"&asp_active=1&asp_force_reset_pagination=1&p_asid="+i.o.id+"&p_asp_data=1&"+s("form",i.n("searchsettings")).serialize();return p=p.replace("?&","?"),p=p.replace("&&","&"),p},d.plugin.getCurrentLiveURL=function(){const a=this,i=new URL(window.location.href);let e;return i.hash="",e=i.href,e=e.indexOf("asp_ls=")>-1?e.slice(0,e.indexOf("asp_ls=")):e,e=e.indexOf("asp_ls&")>-1?e.slice(0,e.indexOf("asp_ls&")):e,e=e.indexOf("p_asid=")>-1?e.slice(0,e.indexOf("p_asid=")):e,e=e.indexOf("asp_")>-1?e.slice(0,e.indexOf("asp_")):e,a.getLiveURLbyBaseLocation(e)},d.plugin.initLiveLoaderPopState=function(){let a=this;a.liveLoadCache=[],window.addEventListener("popstate",()=>{let i=a.getLiveLoadCache();i!==!1&&(a.n("text").val(i.phrase),l.formData(s("form",a.n("searchsettings")),i.settings),a.resetNoUISliderFilters(),a.liveLoad(i.selector,document.location.href,!1,!1,i))}),ASP.pageHTML===""&&typeof ASP._ajax_page_html>"u"&&(ASP._ajax_page_html=!0,s.fn.ajax({url:a.currentPageURL,method:"GET",success:function(i){ASP.pageHTML=i},dataType:"html"}))},d.plugin.setLiveLoadCache=function(a,i){let e=this;e.liveLoadCache.filter(r=>r.href===document.location.href).length===0&&e.liveLoadCache.push({href:a===ASP.pageHTML?e.currentPageURL:document.location.href,phrase:a===ASP.pageHTML?"":e.n("text").val(),selector:i,html:a,settings:a===ASP.pageHTML?e.originalFormData:l.formData(s("form",e.n("searchsettings")))})},d.plugin.getLiveLoadCache=function(){let i=this.liveLoadCache.filter(e=>e.href===document.location.href);return i.length>0?i[0]:!1};var x=null,S=d;Object(window.WPD).AjaxSearchPro=m.default})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.