function PopulateErrorDictionary(){dict={};$("div.m-alert").each(function(){dict[$(this).attr("name")]=$(this).find("p").text()})}function IsValidInput(n){var t=$("#"+n);return t.val().trim()==""&&t.text().trim()==""?(ShowError(n),1):(HideError(n),0)}function ValidateInput(n){return IsValidInput(n)>0?(SetError(n),1):0}function ValidateInputNoError(n){return $("#"+n).val().trim()==""?1:0}function ShowError(n,t){$('div.m-alert.f-error[name="'+n+'"]').show();t!==undefined&&SetError(t)}function HideError(n){$('div.m-alert.f-error[name="'+n+'"]').hide()}function SetError(n){errorText=errorText+"<div>"+dict[n]+"<\/div>"}function HideAllErrors(){$("div.m-alert.f-error").hide();errorText=""}function ShowAllErrors(){$(".hideLeft").html(errorText);$("html, body").animate({scrollTop:$(".m-alert.f-error:visible").first().position().top},"slow")}function GetQueryParameterByName(n){n=n.replace(/[\[\]]/g,"\\$&");var i=new RegExp("[?&]"+n+"(=([^&#]*)|&|#|$)"),t=i.exec(window.location.href);return t?t[2]?decodeURIComponent(t[2].replace(/\+/g," ")):null:null}function ShowHidePanels(n){$("main.dynamic-panel").hide();$("main.dynamic-panel").attr("hidden","true");$("#"+n).show();$("#"+n).attr("hidden","false");$(window).scrollTop(0)}function FormatFileSize(n,t){if(n==0)return"0 Bytes";var i=1024,r=Math.floor(Math.log(n)/Math.log(i));return(n/Math.pow(i,r)).toFixed(t)+" "+["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"][r]}function ShowMore(){for(var t,n=0;n<arguments.length;n++)t=$("#"+arguments[n]).html(),$("#"+arguments[n]).empty().append(t).find(":button").attr("aria-hidden","false").css("display","inline-block")}function SetExpirationDate(){var t=["January","February","March","April","May","June","July","August","September","October","November","December"],n=new Date;n.setYear(n.getFullYear()+5);$("#ExpirationDateMonth").attr({"aria-label":"Month: "+t[n.getMonth()],"data-active-value":t[n.getMonth()]}).html(t[n.getMonth()]);$("#ExpirationDateYear").attr({"aria-label":"Year: "+n.getFullYear(),"data-active-value":n.getFullYear()}).html(n.getFullYear());$("#ExpirationDateDay").attr({"aria-label":"Day: "+("0"+n.getDate()).slice(-2),"data-active-value":("0"+n.getDate()).slice(-2)}).html(("0"+n.getDate()).slice(-2))}function InitAjax(){$(document).ajaxSend(function(n,t){xhrPool.push(t)});$(document).ajaxComplete(function(n,t){xhrPool=$.grep(xhrPool,function(n){return n!=t})});window.abortAllUploadingChunks=function(){$.each(xhrPool,function(n,t){t.abort()})}}var errorText="",dict={},xhrPool=[]