function openWindow(n,t,i,r){return openWindow(n,t,i,r,!1)}function openWindow(n,t,i,r,u){return window.open(n,t,"toolbar=0,scrollbars="+(u?"1":"0")+",status=0,width="+i+",height="+r)}function clearTextBox(n){n._clearedonce||(n.value="",n._clearedonce=!0)}function goSearch(n,t){(n.length>0||t>0)&&(document.location.href=relpath+"search.aspx?q="+(n||"")+"&ca="+(t>0?t:""))}function trackOutgoing(n){$.ajax({type:"GET",url:n})}function includeJS(n){var t=document.createElement("script");t.setAttribute("type","text/javascript");t.setAttribute("src",n);document.getElementsByTagName("head")[0].appendChild(t)}function out2D(n){return n<10?"0"+n:n}function reloadPage(){document.location.href=document.location.href}function showhide(n,t){t&&(t.style.display=n?"none":"")}function BookmarkItem(n,t,i){var r=relpath+"handlers/registrant.ashx",u={command:"bookmarkitem",i:t,bm:i};$.ajax({type:"GET",url:r,data:u,success:function(t){BookmarkItem_Success(t,n)},error:function(n){BookmarkItem_Failure(n)}})}function BookmarkItem_Success(n,t){var i=$(n).find("response"),r,u;switch(i.attr("type")){case"success":r=i[0].getElementsByTagName("fieldstate")[0].firstChild.nodeValue;u=i[0].getElementsByTagName("fielditemid")[0].firstChild.nodeValue;r==1?(t.bset.hide(),t.brem.show()):(t.bset.show(),t.brem.hide());return;case"failure":alert("An error occurred while trying to bookmark this item, please try again!");return}}function BookmarkItem_Failure(){alert("A communication error occurred while trying to bookmark this item, please try again!")}function SubscribeItemNotification(n,t,i){var r=relpath+"handlers/registrant.ashx",u={command:"subscribeitem",i:t,s:i};$.ajax({type:"GET",url:r,data:u,success:function(t){SubscribeItemNotification_Success(t,n)},error:function(n){SubscribeItemNotification_Failure(n)}})}function SubscribeItemNotification_Success(n,t){var i=$(n).find("response"),r,f,u;switch(i.attr("type")){case"success":r=i[0].getElementsByTagName("fieldstate")[0].firstChild.nodeValue;f=i[0].getElementsByTagName("fielditemid")[0].firstChild.nodeValue;r==1?(t.bset.hide(),t.brem.show(),i[0].getElementsByTagName("notificationtype")[0].firstChild.nodeValue==0&&(u=confirm("You have been subscribed to the 'Lot Closing Notification' for this lot.\nHowever you need to edit your subscription settings to enable a notification method (SMS/Email).\nWould you like to go to your subscription settings now?\n\nNotifications are sent about 5 to 10 minutes away from bidding-close.\nEnable notification sending (via SMS/Email) in your subscription settings.\n\n* Live-Bidding auctions send notifications before the lot goes up for live bidding.\n* Timed-Bidding auctions send notifications before the lot's bidding countdown ends.\n* The lot closing notification may not be sent if the auctioneer opens lots out of order,\n  or the auctioneer runs their live-bidding auctions super fast (a few seconds of bidding per lot)."),u&&(window.location.href=window.location.href.indexOf("account")>0?"profile.aspx?m=2&itn=1&returl="+window.location.href:"account/profile.aspx?m=2&itn=1&returl="+window.location.href))):(t.bset.show(),t.brem.hide());return;case"failure":alert("An error occurred while trying to subscribe to the Lot Closing Notification for this item, please try again!");return}}function SubscribeItemNotification_Failure(){alert("A communication error occurred while trying to subscribe to the Lot Closing Notification for this item, please try again!")}function setDefaultButton(n,t){$(n).keypress(function(n){if(n.which&&n.which==13||n.keyCode&&n.keyCode==13)return $(t).click(),!0})}function GoToListing(n,t){var i={command:"findlot",lot:n,as:t,ps:50};$.ajax({type:"GET",url:"handlers/pages/auction.ashx",data:i,success:function(n){GoToListing_Success(n,t)},error:function(n){GoToListing_Failure(n,t)}})}function GoToListing_Success(n,t){var i=$(n).find("response"),r;switch(i.attr("type")){case"success":var u=i[0].getElementsByTagName("pgnumber")[0].firstChild.nodeValue,f=i[0].getElementsByTagName("pgsize")[0].firstChild.nodeValue,e=i[0].getElementsByTagName("auctionid")[0].firstChild.nodeValue;t=i[0].getElementsByTagName("sessionid")[0].firstChild.nodeValue;r=i[0].getElementsByTagName("itemid")[0].firstChild.nodeValue;location.href="auction.aspx?a="+e+"&as="+t+"&p="+u+"&ps="+f+"#i"+r;return;case"failure_lotnotfound":case"failure_invalidlot":default:GoToListing_Failure(null,sessionid);return}}function GoToListing_Failure(n,t){location.href="auction.aspx?as="+t}function GoToPage(n,t,i,r){var f={command:"getpage",i:n,as:t,ps:i||50},u="handlers/pages/auction.ashx",e=window.location.pathname;e.indexOf("/mobile/")!==-1&&(u="../"+u);$.ajax({type:"GET",url:u,data:f,success:function(n){GoToPage_Success(n,t,r)},error:function(n){GoToPage_Failure(n,t,r)}})}function GoToPage_Success(n,t,i){var r=$(n).find("response"),u,f;switch(r.attr("type")){case"success":u=r[0].getElementsByTagName("pgnumber")[0].firstChild.nodeValue;t=r[0].getElementsByTagName("sessionid")[0].firstChild.nodeValue;f=r[0].getElementsByTagName("itemid")[0].firstChild.nodeValue;location.href="auction.aspx?as="+t+"&p="+u+(i?"#i"+f:"");return;case"Failure_InvalidSession":location.href="auctionlist.aspx";return;case"failure_invalid_item":default:GoToPage_Failure(null,sessionid);return}}function GoToPage_Failure(n,t){location.href="auction.aspx?as="+t}function generateImageURL(n,t,i,r,u,f,e){var o,s,h,c;return f==undefined&&(f="s"),o=new Date(t).getTime()*1e4+621355968000000000,e!=undefined&&e.length>0?(o=(new Date).getTime()*1e4+621355968000000000,s=e.split("."),h="_",(f==""||f.toLowerCase()=="l")&&(h=""),c="",e.indexOf("?")<=0&&(c="?v="+o.toString(16)),u+s[0]+h+f+"."+s[1]+c):n>0?u+"i/"+i+"/"+r+"_1"+f+".jpg?v="+o.toString(16):u+"noimage_s.jpg"}function genFriendlyURL(n){if(n.ItemID<0&&(n.ItemID=0),n.ItemTitle!=undefined){var t=n.ItemTitle.toString();return t!=""&&(t=t.replace(/[^a-zA-Z0-9- ]/g," "),t=$.trim(t),t=t.replace(/\s+/g,"-"),t=t.replace(/-+$|(-)+/g,"-")),t+"_i"+n.ItemID}return""}function genBidInformation(n,t,i){var o=GetBiddingState(n),u,r,f,e;switch(o){case"biddingOpen":return u="",n.AuctionSessionTypeID==4?r="Silent Bidding":n.ItemCurrentBidAmount!=null&&n.ItemCurrentBidAmount>0?n.ItemCurrentBidderUsername!=null&&n.ItemCurrentBidderUsername===i?(u="winningbid",r="You're Winning: "+formatCurrency(n.ItemCurrentBidAmount)):(u="highbid",r=n.ShowWinningBid>0||n.ItemSold==!1?"Current Bid: "+formatCurrency(n.ItemCurrentBidAmount):"Current Bid Undisclosed"):r="No Bids Yet","<li class='placebid'><img src='"+t+"graphics/icons/bid.gif' alt='' /><a href='"+genFriendlyURL(n)+"' title='Click here to place a bid on this lot.'>Place Bid<\/a><span class='linkinfo bidinfo "+u+"'>"+r+"<\/span><\/li>";case"biddingLiveOnly":return"<li><a href='"+genFriendlyURL(n)+"'>Live Bidding Only<\/a><span class='linkinfo bidinfo'>Bids Only Accepted Live<\/span><\/li>";case"biddingOver":return n.LiveSwitch==1?(f='<a href="'+t+"livebid.aspx?as="+n.AuctionSessionID+'" onclick="lag.EmitAnalytics(\'ClickLive\')">Completed<\/a>',"<li class='bidding_livenow bidding_openedlive'><img src='"+t+"graphics/icons/live.gif' alt='' />"+f+"<\/li>"):"<li class='bidding_finished'><img src='"+t+"graphics/icons/done.gif' alt='' /><a>Bidding Closed<\/a><span class='linkinfo bidinfo'>Bidding Has Concluded<\/span><\/li>";case"liveNow":case"liveNowOnly":return f='<a href="'+t+"livebid.aspx?as="+n.AuctionSessionID+'" onclick="lag.EmitAnalytics(\'ClickLive\')">Live Bidding<\/a>',"<li class='bidding_livenow'><img src='"+t+"graphics/icons/live.gif' alt='' />"+f+"<\/li>";case"noBidding":default:return(n.AuctioneerID==1201||n.AuctioneerID==1593||n.AuctioneerID==1793||n.AuctioneerID==1801||n.AuctioneerID==1629||n.AuctioneerID==1882||n.AuctioneerID==1982||n.AuctioneerID==2001||n.AuctioneerID==1021||n.AuctioneerID==2335||n.AuctioneerID==2375||n.AuctioneerID==2379||n.AuctioneerID==2471||n.AuctioneerID==2867)&&getUTCDate(n.AuctionSessionDate).getTime()>getCurrentUTCDate().getTime()&&n.AuctioneerWebsite!=null&&n.AuctioneerWebsite.length>0?(e=(n.AuctioneerWebsite.startsWith("http")?"":"http://")+n.AuctioneerWebsite,"<li><img src='"+t+"graphics/icons/bid.gif' alt='' /><a href='"+e+"' target='_blank' onclick=\"trackOutgoing('"+t+"handlers/trackingoutgoing.ashx?page=auction&amp;i="+n.ItemID+"&amp;as="+n.AuctionSessionID+"&amp;ae="+n.AuctioneerID+"&amp;r="+SiteConfig.registrantID+"&amp;target="+encodeURIComponent(e)+"');\" title='Bid On The Auctioneers Website'>Bid Here<\/a><span class='linkinfo'>On Auctioneer's Website<\/span><\/li>"):"<li class='bidding_none no-bidding'><a>No Online Bidding<\/a><span class='linkinfo'>No Bidding For This Lot<\/span><\/li>"}}function GetBiddingState(n){var i,t;return n.AuctionSessionConcluded==1?"biddingOver":n.AllowBidding==0?"noBidding":(i=n.EnableSpendingLimit&&n.EnableMaxBidLockWhenSpendingLimitLive,n.LiveSwitch==1&&(n.AuctionSessionTypeID===1||n.AuctionSessionTypeID===2)&&n.OpenedLive==null)?n.AuctionSessionTypeID===1&&n.AllowBidding&&!i?"liveNow":"liveNowOnly":n.AuctionSessionTypeID==5?"noBidding":n.LiveSwitch==0&&i&&(n.AuctionSessionTypeID==3||n.AuctionSessionTypeID==4)&&n.OpenedLive==null?"biddingLock_LiveSpendingLimit":n.AuctionSessionTypeID==4&&getUTCDate(n.AuctionSessionDate).getTime()>=getCurrentUTCDate().getTime()?"biddingOpen":n.AuctionSessionTypeID==3&&new Date(n.TimedItemEndTime)>=new Date(n.DBDateTime)?"biddingOpen":(t=new Date,t.setDate(t.getDate()-1),n.AuctionSessionTypeID==1&&getUTCDate(n.AuctionSessionDate).getTime()>=getUTCDate(t).getTime()&&n.OpenedLive==null)?"biddingOpen":n.AuctionSessionTypeID==2&&getUTCDate(n.AuctionSessionDate).getTime()>=getUTCDate(t).getTime()&&n.OpenedLive==null?"biddingLiveOnly":"biddingOver"}function initPagingBars(n,t,i){var u,f,r;if(t>1)if(u=$(".pagingbar_prev"),f=$(".pagingbar_next"),i>1?u.html("<a onclick='setPage("+(parseInt(i)-1)+")'>&lt; Prev<\/a>"):u.empty(),i<t?f.html("<a onclick='setPage("+(parseInt(i)+1)+")'>Next &gt;<\/a>"):f.empty(),t<16)for(r=1;r<=t;r++)$(".pagingbar_pages").append("<a onclick='setPage("+r+")'"+(r==i?"class='active'":"")+">"+r+"<\/a>");else initPagingBars_Pages(n,t,i)}function initPagingBars_Pages(n,t,i){for(var s,h,o=$(".pagingbar_pages"),u=3,f=2,e=parseInt(i),r=1;r<=t&&r<=u;r++)o.append("<a onclick='setPage("+r+")' "+(r==e?"class='active'":"")+">"+r+"<\/a>");for(e>u+f+1&&o.append("<span>. . .<\/span>"),s=u+1,e>u+f+1&&(s=e-f),s>t-u-f*2&&(s=t-u-f*2),h=t-u,e<t-(u+f)&&(h=e+f),h<u+f*2+1&&(h=u+f*2+1),r=s;r<=h;r++)o.append("<a onclick='setPage("+r+")' "+(r==e?"class='active'":"")+">"+r+"<\/a>");for(e<t-(u+f)&&o.append("<span>. . .<\/span>"),r=t-(u-1);r<=t;r++)o.append("<a onclick='setPage("+r+")' "+(r==e?"class='active'":"")+">"+r+"<\/a>")}function formatCurrency(n){return n.toString().length>0?n.toFixed(2).replace(/\d(?=(\d{3})+\.)/g,"$&,"):""}function removeStopWords(n){if(n.length>0){for(var r=getStopWords(),u=n.match(/\w+/g),f={},e=[],i,t=0;t<r.length;t++)f[$.trim(r[t])]=!0;for(t=0;t<u.length;t++)i=$.trim(u[t]).toLowerCase(),f[i]||(i.length>1||!isNaN(i))&&e.push(i);return e.join(" ")}return""}function getStopWords(){return["a","able","about","across","after","all","almost","also","am","among","an","and","any","are","as","at","be","because","been","but","by","can","cannot","could","dear","did","do","does","either","else","ever","every","for","from","get","got","had","has","have","he","her","hers","him","his","how","however","i","if","in","into","is","it","its","just","least","let","like","likely","may","me","might","most","must","my","neither","no","nor","not","of","off","often","on","only","or","other","our","own","rather","said","say","says","she","should","since","so","some","than","that","the","their","them","then","there","these","they","this","tis","to","too","twas","us","wants","was","we","were","what","when","where","which","while","who","whom","why","will","with","would","yet","you","your","ain't","aren't","can't","could've","couldn't","didn't","doesn't","don't","hasn't","he'd","he'll","he's","how'd","how'll","how's","i'd","i'll","i'm","i've","isn't","it's","might've","mightn't","must've","mustn't","shan't","she'd","she'll","she's","should've","shouldn't","that'll","that's","there's","they'd","they'll","they're","they've","wasn't","we'd","we'll","we're","weren't","what'd","what's","when'd","when'll","when's","where'd","where'll","where's","who'd","who'll","who's","why'd","why'll","why's","won't","would've","wouldn't","you'd","you'll","you're","you've"]}function removeIllegalChars(n){return n.length>0?$.trim(n.replace(/\?/g,"").replace(/#/g,"").replace(/&/g,"").replace(/@/g,"").replace(/\$/g,"").replace(/%/g,"").replace(/'/g,"").replace(/\\/g,"")):""}function getCurrentUTCDate(){var n=new Date;return now_utc=new Date(n.getUTCFullYear(),n.getUTCMonth(),n.getUTCDate(),n.getUTCHours(),n.getUTCMinutes(),n.getUTCSeconds())}function getUTCDate(n){var t=new Date(n);return now_utc=new Date(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate(),t.getUTCHours(),t.getUTCMinutes(),t.getUTCSeconds())}function ajaxLoader(n,t){this.options=jQuery.extend({bgColor:"#fff",duration:800,opacity:.8,classOveride:!1},t);this.container=$(n);this.init=function(){var n=this.container,t;this.remove();t=$("<div><\/div>").css({"background-color":this.options.bgColor,opacity:this.options.opacity,width:n.width(),height:n.height(),position:"absolute",top:"0px",left:"0px","z-index":99999}).addClass("ajax_overlay");this.options.classOveride&&t.addClass(this.options.classOveride);n.append(t.append($("<div><\/div>").addClass("ajax_loader")).fadeIn(this.options.duration))};this.remove=function(){var n=this.container.children(".ajax_overlay");n.length&&n.fadeOut(this.options.classOveride,function(){n.remove()})};this.init()}function getKeywordsCount(n){var t=removeStopWords(removeIllegalChars(n));return t.length>0?t.split(" ").length:0}function saveSearch(n,t,i,r,u,f,e,o){var h="",c,s;return e||(h="../"),c={keywords:r.keywords,siteID:f.siteID,categoryID:u.categoryID,auctionSessionTypeID:u.auctionSessionTypeID,countryLocationID:u.countryLocationID,auctioneerID:u.auctioneerID,yearID:u.yearID,registrantID:f.registrantID,ss:t,exactKeywords:r.exactKeywords,myAgent:i,enableMyAgent:o,label:n,hasImage:r.hasImage,command:"savesearch"},s="",$.ajax({type:"GET",url:h+"handlers/account/savedsearch.ashx",data:c,"async":!1,dataType:"html",success:function(n){s=n},error:function(n){s=n}}),s}function generateSavedSearchName(n,t,i){var r="",u;return n!=""&&(r="Filter: "+n,t!=""&&(r+=", ")),t!=""&&(u="",u=i==1||i==!0?"Exact Keywords: ":"Keywords: ",r+=u+t),r}function endsWith(n,t){return n.indexOf(t,n.length-t.length)!==-1}function checkIfSavedSearchExists(n,t,i,r,u){var e="",o,f;return n||(e="../"),o={command:"checkIfExists",keywords:t.keywords,siteID:i.siteID,categoryID:r.categoryID,auctionSessionTypeID:r.auctionSessionTypeID,countryLocationID:r.countryLocationID,auctioneerID:r.auctioneerID,yearID:r.yearID,registrantID:i.registrantID,exactKeywords:t.exactKeywords,hasImage:t.hasImage,ss:u},f=null,$.ajax({type:"GET",url:e+"handlers/account/savedsearch.ashx",dataType:"text",data:o,"async":!1,success:function(n){f=n},error:function(){}}),f}function getTimeZoneName(n){var t;switch(n){case"-720":t="UTC-12";break;case"-660":t="UTC-11";break;case"-600":t="UTC-10";break;case"-570":t="UTC-9:30";break;case"-540":t="UTC-9";break;case"-480":t="UTC-8";break;case"-420":t="UTC-7";break;case"-360":t="UTC-6";break;case"-300":t="UTC-5";break;case"-270":t="UTC-4:30";break;case"-240":t="UTC-4";break;case"-210":t="UTC-3:30";break;case"-180":t="UTC-3";break;case"-120":t="UTC-2";break;case"-60":t="UTC-1";break;case"0":t="UTC";break;case"60":t="UTC+1";break;case"120":t="UTC+2";break;case"180":t="UTC+3";break;case"210":t="UTC+3:30";break;case"240":t="UTC+4";break;case"270":t="UTC+4:30";break;case"300":t="UTC+5";break;case"330":t="UTC+5:30";break;case"345":t="UTC+5:45";break;case"360":t="UTC+6";break;case"390":t="UTC+6:30";break;case"420":t="UTC+7";break;case"480":t="UTC+8";break;case"525":t="UTC+8:45";break;case"540":t="UTC+9";break;case"570":t="UTC+9:30";break;case"600":t="UTC+10";break;case"630":t="UTC+10:30";break;case"660":t="UTC+11";break;case"690":t="UTC+11:30";break;case"720":t="UTC+12";break;case"765":t="UTC+12:45";break;case"780":t="UTC+13";break;case"840":t="UTC+14";break;case"150":t="UTC-2:30";break;default:t="error"}return t}function getMonthName(n){var t=[];return t[0]="Jan",t[1]="Feb",t[2]="Mar",t[3]="Apr",t[4]="May",t[5]="Jun",t[6]="Jul",t[7]="Aug",t[8]="Sep",t[9]="Oct",t[10]="Nov",t[11]="Dec",t[n]}function initAutoPopups(n,t,i){function e(n,t,i,r){clearTimeout(u);$("#TB_window").is(":visible")||(t=t+(/\?/.test(t)?"&":"?"),tb_show(n,t+"TB_iframe=true"+(i?"&width="+i:"")+(r?"&height="+r:"")))}function o(){var n=$(window).height();n=Math.min(n-n*.1,500);e("",i,400,n)}var u,r;lag.ShimLocalStorage();u=null;window.openNewsletterPopup=function(){e("Subscribe to our Newsletter",t,372,510);$("#TB_window").addClass("tb-newsletter-theme")};var f=localStorage.getItem("newsletterpopup")||!1;if(f&&(f=new Date(f)>Date.now()),r=localStorage.getItem("prompt:signup.expiry")||!1,r&&(r=new Date(r)>Date.now()),n==!1&&/(?:register|signup|itembid|login|loginreset|emailreset|help|newsletter|policy|subscribe|unsubscribe|contact)\.as/i.test(document.location.href)==!1){if(/[?&]prompt=signup(?:&|$)/i.test(document.location.search)&&!r)u=setTimeout(o,4e3);else if(/^https?:\/\/(?:\S+\.)?(?:google|yahoo|bing|aol|ask)\.[a-z]{2,5}\//i.test(document.referrer)&&!f)u=setTimeout(openNewsletterPopup,7e3);else return!1;return!0}return!1}function getUtmQueryParamsAsTrackingValue(){const n=function(n){const t=lag.GetURLParam("utm_"+n);return t&&t.trim().length?(n+"="+t).toLowerCase():null},t=n("source");if(!t)return null;const i=[t,n("campaign"),n("medium"),n("term"),n("content")].filter(n=>!!n).join("&");return"UTM:"+i}function getCategoryFilter(n){$.ajaxSetup({cache:!0});$.ajax({type:"GET",url:lag.CommonAPIURL+"categories",data:{as:n.auctionSessionID||0,a:n.auctionID||0},success:function(n){var t="";n.categories.length>1&&n.categories.forEach(function(n){t+=`<option value="${n.categoryID}">${n.displayName||n.name}</option>`});t!=""?($("#ddlSearchCategories").show(),$("#ddlSearchCategories").html($("#ddlSearchCategories").html()+t)):$("#ddlSearchCategories").hide()},error:function(){$("#ddlSearchCategories").hide()}});$.ajaxSetup({cache:!1})}window.lag=window.lag||{},function(){function f(n,t){var i=65535,r=+n,u=+t,f=i&r,e=i&u;return 0|f*e+((i&r>>>16)*e+f*(i&u>>>16)<<16>>>0)}function e(){var n,i,r;try{return(n=JSON.parse(sessionStorage.getItem(t)),!n||!n.data||!n.timestamp)?void 0:(i=parseInt(n.timestamp)||0,r=Date.now()-i,r>u)?void 0:n.data}catch(f){console.error(f)}}function r(n){if(window.sessionStorage){if(!n){sessionStorage.removeItem(t);return}if(typeof n!="object")throw new Error("c.js:_putCachedUserPreferences:prefsObject:not-object");var i={timestamp:Date.now(),data:n};try{i=JSON.stringify(i);sessionStorage.setItem(t,i)}catch(r){console.error(r)}}}window.relpath=window.relpath||"";var i=null,n=null,t="lag-user-prefs",u=864e5;lag.GetCommonApiURL=function(){var n=document.location.hostname;return n.match(/(localhost|localsite|local)/i)?"http://localhost:8001/":n.match(/\w+\.local\.liveauctiongroup\.net/i)?"https://common.api.test.liveauctiongroup.net/":n.match(/sandbox\.liveauctiongroup\.com/i)?"https://common.api.test.liveauctiongroup.net/":"https://common.api.liveauctiongroup.net/"};lag.CommonAPIURL=lag.GetCommonApiURL();lag.GetURLParam=function(t){var o,f,r,u,e;if((n==null||i!==document.location.search)&&(i=document.location.search,n={},o=/([^&=]+)=?([^&]*)/g,r=document.location.search,r&&r.length))for(r[0]==="?"&&(r=r.substr(1)),r=r.replace(/\+/g," ");f=o.exec(r);)u=decodeURIComponent(f[1]),e=decodeURIComponent(f[2]),n[u]!==undefined?($.isArray(n[u])||(n[u]=[n[u]]),n[u].push(e)):n[u]=e;return n[t]};lag.ChangeURLParam=function(n,t,i){var u,r,f;return t?(u=new RegExp("([?&])("+t+")=[^&]*(&?)"),r="",n.indexOf("#")>0&&(r=n.substr(n.indexOf("#")),n=n.substr(0,n.indexOf("#"))),n.search(u)>=0?i||i==0||t=="q"?n.replace(u,"$1$2="+i+"$3")+r:(t=="is"&&alert(i.toString()),n.replace(u,"$1").replace(/[?&]$/,"")+r):i==null?n:(f="",n.match(/([?&])?$/)[1]||(f=n.indexOf("?")>0?"&":"?"),n+f+t+"="+i+r)):n};lag.ShimLocalStorage=function(){function n(n){var t=n?"":" expires=Tue, 19 Jan 2038 03:14:07 GMT;";return{getItem:function(n){return!n||!this.hasOwnProperty(n)?null:unescape(document.cookie.replace(new RegExp("(?:^|.*;\\s*)"+escape(n).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=\\s*((?:[^;](?!;))*[^;]?).*"),"$1"))},key:function(n){return unescape(document.cookie.replace(/\s*\=(?:.(?!;))*$/,"").split(/\s*\=(?:[^;](?!;))*[^;]?;\s*/)[n])},setItem:function(n,i){n&&(document.cookie=escape(n)+"="+escape(i)+";"+t+"path=/",this.length=document.cookie.match(/\=/g).length)},length:0,removeItem:function(n){n&&this.hasOwnProperty(n)&&(document.cookie=escape(n)+"=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/",this.length--)},hasOwnProperty:function(n){return new RegExp("(?:^|;\\s*)"+escape(n).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=").test(document.cookie)}}}window.localStorage||(window.localStorage=n(!1),window.localStorage.length=(document.cookie.match(/\=/g)||window.localStorage).length);window.sessionStorage||(window.sessionStorage=n(!0),window.sessionStorage.length=(document.cookie.match(/\=/g)||window.sessionStorage).length)};lag.PolyfillSendBeacon=function(){!function(n,t){"object"==typeof exports&&"undefined"!=typeof module?t():"function"==typeof define&&define.amd?define(t):t()}(0,function(){"use strict";function n(t){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(n){return typeof n}:function(n){return n&&"function"==typeof Symbol&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n})(t)}var t=function(n){return"string"==typeof n},i=function(n){return n instanceof Blob};(function(){(function(){return"navigator"in this&&"sendBeacon"in this.navigator}).call(this)||("navigator"in this||(this.navigator={}),this.navigator.sendBeacon=function(n,r){var f=this.event&&this.event.type,e="unload"===f||"beforeunload"===f,u="XMLHttpRequest"in this?new XMLHttpRequest:new ActiveXObject("Microsoft.XMLHTTP");u.open("POST",n,!e);u.withCredentials=!0;u.setRequestHeader("Accept","*/*");t(r)?(u.setRequestHeader("Content-Type","text/plain;charset=UTF-8"),u.responseType="text/plain"):i(r)&&r.type&&u.setRequestHeader("Content-Type",r.type);try{u.send(r)}catch(n){return!1}return!0}.bind(this))}).call("object"===("undefined"==typeof window?"undefined":n(window))?window:void 0)})};lag.EmitAnalytics=function(n){n&&n.length&&(window.dataLayer&&dataLayer.push({event:n}),window.fbq&&fbq("trackCustom",n))};lag.CachedValues=function(n,t){function u(){try{var n=sessionStorage.getItem(r);return n?JSON.parse(n):{}}catch(t){return{}}}function f(n){sessionStorage.setItem(r,JSON.stringify(n))}if(!n||!t)throw new Error("c.js:lag.CachedValues:missing-params");var i=this===window?{}:this,r="phoenix_cachedvals_"+n;return i.getVal=function(n){if(!n)throw new Error("c.js:lag.CachedValues.getVal:missing-params");var i=u(),r=i[t]||{};return r[n]},i.getIntVal=function(n){var t=i.getVal(n);return t?parseInt(t):0},i.setVal=function(n,i){if(!n||typeof n!="object")throw new Error("c.js:lag.CachedValues.setVal:missing-params");var r=u(),e=r[t]||{};r[t]=i?Object.assign(e,n):n;f(r)},i};lag.hashString=function(n,t){var u=u||f;t=t||0;let i=3735928559^t,r=1103547991^t;for(let t=0,f;t<n.length;t++)f=n.charCodeAt(t),i=u(i^f,2654435761),r=u(r^f,1597334677);return i=u(i^i>>>16,2246822507),i^=u(r^r>>>13,3266489909),r=u(r^r>>>16,2246822507),r^=u(i^i>>>13,3266489909),4294967296*(2097151&r)+(i>>>0)};Number.prototype.toMoney=function(n,t,i){var u=this,e=isNaN(n)?2:Math.abs(n),s=t||".",o=typeof i=="undefined"?",":i,h=u<0?"-":"",f=parseInt(u=Math.abs(u).toFixed(e))+"",r=(r=f.length)>3?r%3:0;return h+(r?f.substr(0,r)+o:"")+f.substr(r).replace(/(\d{3})(?=\d)/g,"$1"+o)+(e?s+Math.abs(u-f).toFixed(e).slice(2):"")};lag.GetUserPreferences=function(){var n,t,i;try{return(n=e(),n)?Promise.resolve(n):(t=document.location.href.match(/^(https?:\/\/[^/]+)(\/phoenix\/www)?/i),i=t[1]+(t[2]||""),fetch(i+"/handlers/registrant.ashx?command=prefs").then(function(n){return n.ok&&n.json()}).then(function(n){return!n||typeof n!="object"?null:(r(n),n)}).catch(n=>{console.error(n)}))}catch(u){return console.error(u),Promise.reject()}};lag.ClearCachedUserPreferences=function(){r(null)};lag.CheckInstantApproveEligible=function(n,t){try{return lag.GetUserPreferences().then(function(i){var r,u;return!i||!i.InstantApprovingAuctioneers?!1:(r=i.InstantApprovingAuctioneers[n],typeof r!="string")?!1:!t||!t.length?!0:(u=r.split(",").filter(function(n){return n}),u.includes(t))}).catch(function(n){console.error(n)})}catch(i){return console.error(i),Promise.reject()}}}(),function(){var t,i,n,r;if((lag.ShimLocalStorage(),lag.PolyfillSendBeacon(),t=new Date(sessionStorage.getItem("phoenix_session")||0),i=108e5,!(Date.now()-t.valueOf()<i))&&(sessionStorage.setItem("phoenix_session",(new Date).toUTCString()),n=lag.GetURLParam("t"),n&&typeof n=="string"&&n.length||(n=null),n||(n=getUtmQueryParamsAsTrackingValue()),r=document.referrer&&document.referrer.indexOf(document.location.hostname)<0&&document.referrer.indexOf("liveauctiongroup.")<0,n||r)){var u=Math.floor(Math.random()*100000000000000000),f=(relpath||document.location.origin+"/")+"handlers/tracking.ashx?_="+u,e=(n||"").replace("|","")+"|"+(document.location.href||"").replace("|","")+"|"+(document.referrer||"").replace("|","");$.post(f,encodeURIComponent(e))}}();