var a,isNS=document.layers?true:false,isIE=document.all?true:false,isIE6=isIE&&window.clientInformation.appVersion.indexOf("MSIE 6")>-1,server=document.location.protocol+"//"+document.location.host+"/",TDataTypes=["dtBoolean","dtDateTime","dtDouble","dtInteger","dtString","dtMoney","dtPercentage","dtLong","dtGuid"],dtBoolean=0,dtDateTime=1,dtDouble=2,dtInteger=3,dtString=4,dtMoney=5,dtPercentage=6,dtLong=7,dtGuid=8,bodyLoaded=false,image=document.createElement("IMG"),kaTimer=setTimeout("keepAlive();",
12E4),pageSize=null,winSize=null,lightBoxes=new TLightBoxes,messageBox=new TLightBox("divMessage",2E3,200,imgBack);if(!window.XMLHttpRequest&&window.ActiveXObject)window.XMLHttpRequest=function(){for(var b=["Microsoft.XMLHTTP","MSXML2.XMLHTTP"],c=b.length;c--;)try{return new ActiveXObject(b[c])}catch(d){}throw new Error("No XML support in this browser.");};
if(!document.getElementByName)document.getElementByName=function(b){var c=document.getElementsByName(b);if(c.length>0)return c[0];else throw new Error('Element with name "'+b+'" not found.');};window.onresize=function(){bodyResize(document.body)};var browsers={unknown:0,IE:1,firefox:2,netscape:3,mozilla:4,opera:5,safari:6,chrome:7};
function bodyLoad(b,c){bodyResize(b);try{if(typeof document.documentElement!="undefined")document.documentElement.onscroll=function h(){bodyScroll(document.documentElement)}}catch(d){}if(c){window.print();window.close()}else{lightBoxes.init();if(messageBox.initialized()){var e=1E4,f=Html.get("divMessageText");c=Html.get("btnCloseMessage");messageBox.show();if(f){e=String(f.innerText).length;e=Math.max(Math.floor(e/80*7E3),5E3)}setTimeout("messageBox.hide();",e);if(c)try{c.focus()}catch(g){}}typeof menu!=
"undefined"&&menu.Class&&menu.Class=="TMenu"&&menu.initialize();isIE6&&checkAnchors()}typeof doWizards!="undefined"&&doWizards();typeof customBodyLoad!="undefined"&&customBodyLoad(b);bodyLoaded=true}function bodyResize(b){var c=Html.get("__asptrace");if(c){c.style.width="12px";c.style.overflow="hidden"}winSize=pageSize=null;var d=getSize(szPage);lightBoxes.position(d);if(c)c.style.width=d.width+"px";typeof customBodyResize!="undefined"&&customBodyResize(b,d)}
function bodyScroll(b){var c=getSize(szPage);lightBoxes.position(c);typeof customBodyScroll!="undefined"&&customBodyScroll(b)}function clearElement(b,c){if(b.value==b.defaultValue)b.value=""}function positionElement(b,c){var d=document.documentElement,e=d.scrollTop+c,f=getSize(szWindow);if(c+b.offsetHeight+20>f.height){e=d.scrollTop+f.height-b.offsetHeight-20;if(e<d.scrollTop)e=d.scrollTop}b.style.top=e+"px"}
function closeMessage(b){b=findForm();messageBox.initialized()&&messageBox.hide();b&&frmFormReady&&frmFormReady(b.ID)}function findForm(){if(document.forms)for(var b=0;b<document.forms.length;b++){var c=document.forms[b],d=String(c.name);if(d.startsWith("frmForm_")){b=parseInt(d.split("_")[1]);c.ID=b;return c}}}function intInputKeyPress(b,c){if([8,9,13,45,48,49,50,51,52,53,54,55,56,57].contains(c.keyCode||c.charCode))return c.returnValue=true;else return c.returnValue=false}
function floatInputKeyPress(b,c){var d=c.keyCode||c.charCode;if([8,9,13,44,45,46,48,49,50,51,52,53,54,55,56,57].contains(d))if(d==44||d==46){if(b.value.length==0||b.value.indexOf(".")>-1||b.value.indexOf(",")>-1)return c.returnValue=false}else return c.returnValue=true;else return c.returnValue=false}
function datetimeInputKeyPress(b,c){b=Date.formatInfo;for(var d=[8,9,13,32,48,49,50,51,52,53,54,55,56,57,58],e=0;e<b.dateSeparator.length;e++)d.add(b.dateSeparator.charCodeAt(e));for(e=0;e<b.timeSeparator.length;e++)d.add(b.timeSeparator.charCodeAt(e));if(d.contains(c.keyCode||c.charCode))return true;else{c.cancelBubble=true;return c.returnValue=false}}
function dateInputKeyPress(b,c){b=Date.formatInfo;for(var d=[8,9,13,48,49,50,51,52,53,54,55,56,57],e=0;e<b.dateSeparator.length;e++)d.add(b.dateSeparator.charCodeAt(e));if(d.contains(c.keyCode||c.charCode))return true;else{c.cancelBubble=true;return c.returnValue=false}}
function timeInputKeyPress(b,c){b=Date.formatInfo;for(var d=[8,9,13,48,49,50,51,52,53,54,55,56,57,58],e=0;e<b.timeSeparator.length;e++)d.add(b.timeSeparator.charCodeAt(e));if(d.contains(c.keyCode||c.charCode))return true;else{c.cancelBubble=true;return c.returnValue=false}}function checkAnchors(){for(var b=document.getElementsByTagName("a"),c=0;c<b.length;c++){var d=b[c];if(!d.href)d.className="anchor"}}
function rndString(b){if(typeof b=="undefined")b=16;for(var c="",d=0;d<b;d++)c+="1234567890abcdefghiklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ".substr(Math.floor(Math.random()*61),1);return c}
function setStats(){var b="steID="+steID;if(typeof itmID!="undefined")b+="&itmID="+itmID;else if(typeof catID!="undefined")b+="&catID="+catID;screen?document.writeln('<div id="divStats"><img src="misc/default/setStats.aspx?ColorDepth='+screen.colorDepth+"&ScreenWidth="+screen.width+"&ScreenHeight="+screen.height+"&"+b+'" width="1" height="1" alt="stats" align="right"/></div>'):document.writeln('<div id="divStats"><img src="misc/default/setStats.aspx?'+b+'" width="1" height="1" alt="stats" align="right"/></div>')}
function keepAlive(){kaTimer&&clearTimeout(kaTimer);if(!(new Url).server().startsWith("http://localhost:")){document.body.appendChild(image);image.src="misc/keepAlive.aspx?str="+rndString();kaTimer=setTimeout("keepAlive();",12E4)}}function resizeFont(b,c,d){var e=getCookie("FontSize");e=e?parseInt(e):1;e=typeof d!="undefined"?d:e==1?3:1;document.body.style.fontSize=60+e*10+"%";setCookie("FontSize",e);typeof onFontResize!="undefined"&&onFontResize(b,c,d);return 60+e*10}
function printItem(b){var c=(new Url).remove("msg");if(typeof b!="undefined")c=c.remove("catID").add("itmID",b);(b=window.open(c.replacePage("printItem.aspx"),"printItem","menubar=0,location=0,toolbar=0,scrollbars=0,resizable=0,status=0,width=560,height=470"))&&b.focus()}function printPage(){printItem()}
function sendItem(b){var c=Html.get("divSendItem"+b),d=Html.get("aSend"+b);if(c){for(include("js/default/effects.js");typeof Effect=="undefined";){setTimeout("sendItem("+b+")",100);return}var e=Html.get("divBookItem"+b);e&&e.style.display!="none"&&Resources.hideForm(b);if(c.style.display=="none"){d&&Html.addClass(d,"active");Effect.SlideDown("divSendItem"+b,{duration:0.3});c.style.display=""}else{d&&Html.removeClass(d,"active");Effect.SlideUp("divSendItem"+b,{duration:0.3});c.style.display="none"}}else{b=
(new Url).remove("msg");(b=window.open(b.replacePage("sendItem.aspx"),"sendItem","menubar=0,location=0,toolbar=0,scrollbars=0,resizable=0,status=0,width=400,height=290"))&&b.focus()}}function editItem(b){var c=(new Url).remove("msg");c=c.add("itmID",b);c=c.add("action",1);document.location.href=c}
function displayImage(b){var c=new Url(b);if(b.indexOf(".aspx")==-1)c=new Url("misc/showFile.aspx?File="+b);b=(new Url).replacePage("misc/default/showImage.aspx",true).add("Filename",c.get("Filename")).add("File",c.get("File"));(b=window.open(b,"showFile","menubar=0,location=0,toolbar=0,scrollbars=1,resizable=1,status=1,width=50,height=50,top=25,left=25"))&&b.focus()}
function resizeWin(){var b=Html.get("imgMain"),c=b.offsetWidth;b=b.offsetHeight;isIE6?window.resizeTo(c+45,b+70):window.resizeTo(c+45,b+95)}function alertWin(b,c,d){var e=null;if(e=typeof c!="undefined"&&typeof d!="undefined"?window.open("",c,d):typeof c!="undefined"?window.open("",c):typeof d!="undefined"?window.open("","",d):window.open()){e.document.open();e.document.write(b);e.document.close()}}
function frmSendLinkSubmit(b,c){var d=b.elements.edtName;b=b.elements.edtEmail;if(String(d.value)==""){alert(nameEmpty[Languages.current]);d.focus();return c.returnValue=false}if(String(b.value)==""){alert(eMailEmpty[Languages.current]);b.focus();return c.returnValue=false}if(!isEmail(b.value)){alert(eMailInvalid[Languages.current]);b.focus();return c.returnValue=false}return true}
function cookieName(b){b=escape(b);b=b.replace(/@/gi,"%40");b=b.replace(/\*/gi,"%2A");b=b.replace(/-/gi,"%2D");b=b.replace(/_/gi,"%5F");b=b.replace(/\+/gi,"%2B");b=b.replace(/\./gi,"%2E");return b=b.replace(/\//gi,"%2F")}function getCookie(b){b=cookieName(b);var c=document.cookie,d=c.indexOf(" "+b+"=");if(d==-1)d=c.indexOf(b+"=");if(d==-1)return null;d=c.indexOf("=",d)+1;b=c.indexOf(";",d);if(b==-1)b=c.length;return unescape(c.substring(d,b))}function removeCookie(b){setCookie(b)}
function setCookie(b,c,d){b=cookieName(b);if(c!=null&&typeof c!="undefined"&&String(c)!=""){var e=(new Date).nextYear();if(arguments.length>2)e=d;document.cookie=e==null?b+"="+escape(c)+"; path=/":b+"="+escape(c)+"; path=/;expires="+e.toGMTString()}else document.cookie=b+"=; path=/;expires="+(new Date).priorDay().toGMTString()}function toggleDisplay(b){if(typeof b=="string")b=Html.get(b);if(typeof b=="object")b.style.display=b.style.display=="none"?"":"none"}var checking=false;
function checkBoxListClick(b,c,d){if(!checking){checking=true;c=document.getElementsByName(d);if(b.id.endsWith("All"))for(d=0;d<c.length;d++)c[d].checked=b.checked;else if(b=Html.get(d+"All")){var e=true;for(d=0;d<c.length;d++)c[d].checked||(e=false);b.checked=e}checking=false}}function isChildOf(b,c){return typeof b.contains!="undefined"?b.contains(c):c==null?false:b==c?true:isChildOf(b,c.parentNode)}function isParentOf(b,c){return isChildOf(c,b)}
TEvent=function(b,c,d){this.object=b;this.event=c;this.func=d};TEvent.first=null;TEvent.events=[];TEvent.find=function(){for(var b=0;b<arguments.length;b++)try{return eval(arguments[b])}catch(c){}return null};TEvent.unload=function(){if(TEvent.events!=null){removeEvent(window,"unload",TEvent.first);for(var b=0;b<TEvent.events.length;b++){var c=TEvent.events[b];c.event!="unload"&&removeEvent(c.object,c.event,c.func)}TEvent.first=null;TEvent.events=null}};
function addEvent(b,c,d){if(typeof b=="string")b=Html.get(b);if(typeof d=="string")d=new Function("event",d);if(b.attachEvent){b.attachEvent("on"+c,d);if(!TEvent.first){TEvent.first=new Function("event","TEvent.unload( event );");window.attachEvent("onunload",TEvent.first)}}else{b.addEventListener(c,d,false);if(!TEvent.first){TEvent.first=new Function("event","TEvent.unload( event );");window.addEventListener("unload",TEvent.first,false)}}TEvent.events.add(new TEvent(b,c,d));return d}
function cancelEvent(b){if(typeof b=="undefined"||b==null)return false;b.cancelBubble=true;if(typeof b.preventDefault=="function")b.preventDefault();else if("returnValue"in b)b.returnValue=false;return false}
function createEvent(b){var c="click";if(typeof b=="string"){c=b;b=null}else if(typeof b!="undefined"&&typeof b.type!="undefined")c=b.type;var d=b?b.charCode||b.keyCode:null,e=b?b.srcElement||b.target:null;return{altKey:b?b.altKey:false,button:b?b.button:null,bookmarks:b?b.bookmarks:[],boundElements:b?b.boundElements:[],cancelBubble:b?b.cancelBubble:false,clientX:b?b.clientX:0,clientY:b?b.clientY:0,ctrlKey:b?b.ctrlKey:false,fromElement:b?b.fromElement:null,keyCode:b?d:0,offsetX:b?b.offsetX:0,offsetY:b?
b.offsetY:0,reason:b?b.reason:null,returnValue:b?b.returnValue:true,screenX:b?b.screenX:0,screenY:b?b.screenY:0,shiftKey:b?b.shiftKey:false,srcElement:b?e:null,srcFilter:b?b.srcFilter:null,target:b?e:null,toElement:b?b.toElement:null,type:b?b.type:c,x:b?b.x:0,y:b?b.y:0}}function filterEvent(b){return String(b).replace(/^function \w+\((event)?\)\s*{\s*((.|\n)*)\s*}/,"$2")}
function removeEvent(b,c,d){if(typeof b=="string")b=Html.get(b);try{b.detachEvent?b.detachEvent("on"+c,d):b.removeEventListener(c,d,false)}catch(e){}}
function valueString(b){var c=typeof b,d="";if(c=="boolean")return b?"true":"false";else if(c=="number")return b;else if(c=="string")return'"'+b+'"';else if(c=="undefined")return"undefined";else if(b==null)return"null";else if(b instanceof Array){for(var e=0;e<b.length;e++)d+=", "+valueString(b[e]);return d.length?"["+d.substr(2)+"]":"[]"}else if(b instanceof Date)return"#"+b.formatString("s").replace("T"," ")+"#";else if(b instanceof RegExp)return b.toString();else if(c=="function"){b=String(b);
return b.substr(0,b.indexOf(")")+1)}else if(c=="object"){if(typeof b.nodeName!="undefined"){c=b.nodeName;if(c=="#text"||c=="#cdata")return b.nodeName+'["'+b.nodeValue+'"]';else if(typeof b.attributes!="undefined"){if(b.attributes)for(e=0;e<b.attributes.length;e++){var f=b.attributes[e];if(f.nodeValue!=""&&f.nodeValue!="inherit"&&f.nodeValue!=null&&!String(f.nodeValue).startsWith("function"))d+=" "+f.nodeName+'="'+f.nodeValue+'"'}return typeof b.nodeType!="undefined"&&b.nodeType==2?"@"+c+'= "'+b.nodeValue+
'"':"<"+c+d+"/>"}else return typeof b.location!="undefined"?"window"+(window.name?'["'+b.name+'"]':""):"<"+c.toLowerCase()+(b.id?' id="'+b.id+'"':"")+(b.className?' class="'+b.className+'"':"")+"/>"}if(typeof b.Class!="undefined"){d=b.Class;return d=="Point"?"Point("+b.left+", "+b.top+")":d=="Size"?"Size("+b.width+", "+b.height+")":d=="Url"?'Url("'+b.toString()+'")':d=="Rgb"?"Rgb("+b.red+", "+b.green+", "+b.blue+') {"'+b.toHex()+'"}':d=="TWizard"||d=="TTable"||d=="TColumn"?typeof b.owner=="undefined"?
d+'("'+b.name+'")':valueString(b.owner)+"."+d+'("'+b.name+'")':d=="TField"?valueString(b.owner.owner)+".TRow["+b.owner.index+"]."+d+'("'+b.name+'")':d=="TMenuItem"?d+"["+b.id+"]":typeof b.ID!="undefined"?d+"["+valueString(b.ID)+"]":d=="KeyStroke"?b.toString():d}if(typeof b.toString!="undefined"){d="";try{for(e in b)d+=", "+e+": "+valueString(b[e]);if(d.length)d="{"+d.substr(2)+"}"}catch(g){d=""}return b.toString().replace(/^\[object( [^\]]+)\]$/gi,"$1")+d}if(typeof b.srcElement!="undefined"||typeof b.target!=
"undefined")return typeof b.type!="undefined"?"event[type = "+b.type+"]":"event";try{return String(b)}catch(h){return'unhandled type: "'+typeof b+'". String( value ): '+h.message}}else return'unhandled type: "'+typeof b+'"'}function parseBool(b){var c=parseInt(b);return String(b).substr(0,4).toLowerCase()=="true"||!isNaN(c)&&c!=0?true:String(b).substr(0,5).toUpperCase()=="false"||!isNaN(c)&&c==0?false:null}
function isSame(b,c,d){if(typeof d=="undefined"){d=typeof b;if(d==typeof c){if(b==null&&c==null)return true;else if(b==null||c==null)return false;if(typeof b.Class!="undefined"&&typeof c.Class!="undefined")if(b.Class==c.Class)return b==c;if(d=="string"){b=b.replace(/\r\n/gi,"\n");c=c.replace(/\r\n/gi,"\n")}return b.toString()==c.toString()}else return false}else try{b=convert(b,d);c=convert(c,d);return this.isSame(b,c)}catch(e){}return false}
function convert(b,c){if(b==null||String(b)=="")return null;switch(c){case dtBoolean:return String(b).toLowerCase()=="false"||String(b)=="0"?false:true;case dtDateTime:c=isDateTime(b);if(c!=false)return new Date(c);else{c=parseXmlDate(b);if(isNaN(c))throw new Error(getIllegalDateMessage());else return c}case dtPercentage:if(String(b).endsWith("%"))b=String(b).substr(0,String(b).length-1);case dtDouble:case dtMoney:if(typeof b!="number"){c=Number.formatInfo;if(c.groupingSeparator=="."&&!b.contains(c.decimalSeparator))b=
String(b).replace(new RegExp("\\"+c.groupingSeparator+"{1}","gi"),c.decimalSeparator);b=String(b).replace(new RegExp("\\"+c.groupingSeparator,"gi"),"");b=b.replace(c.currencySymbol,"");b=b.trim();b=b.replace(new RegExp("\\"+c.decimalSeparator,"gi"),".")}if(!isNumeric(b))if(b=getMessage(17))throw new Error(b.text);else throw new Error("De ingevoerde waarde is niet correct. Er wordt een getal verwacht.");return parseFloat(b);case dtInteger:case dtLong:if(!String(b).match(/\d{1,10}/gi))if(b=getMessage(16))throw new Error(b.text);
else throw new Error("De ingevoerde waarde is niet correct. Er wordt een geheel getal verwacht.");return parseInt(b);case dtString:case dtGuid:return String(b);default:throw new Error('Illegal assignment to parameter "type" ('+c+").");}}function getBackColor(b){if(typeof b=="string")b=Html.get(b);var c=Element.getStyle(b,"background-color");if(b.parentNode!=null)if(c=="transparent"||c.startsWith("rgba(0, 0, 0, 0)"))c=getBackColor(b.parentNode);return c}
function getColor(b){if(typeof b=="string")b=Html.get(b);var c=Element.getStyle(b,"color");return c=="transparent"||c.startsWith("rgba(0, 0, 0, 0)")?b.parentNode!=null?getColor(b.parentNode):c:c}function rgbToHex(b){if(isIE)return b.replace("#","");else{if(b.startsWith("rgb(")){b=b.substr(4);b=b.substr(0,b.length-1);b=b.split(", ")}return toHex(b[0])+toHex(b[1])+toHex(b[2])}}function twoDigit(b){return b.length==1?"0"+b:b}
Rgb=function(b,c,d){this.Class="Rgb";if(b=="transparent"){this.blue=this.green=this.red=128;this.transparent=true}else{if(typeof b=="undefined"||b==null)b=255;if(typeof c=="undefined"||c==null)c=255;if(typeof d=="undefined"||d==null)d=255;this.red=b;this.green=c;this.blue=d;this.transparent=false}};
Rgb.prototype.lighter=function(b){if(this.transparent)return this;if(typeof b=="undefined")b=5;var c=Math.round(this.red*(100+b)/100),d=Math.round(this.green*(100+b)/100);b=Math.round(this.blue*(100+b)/100);return new Rgb(Math.min(c,255),Math.min(d,255),Math.min(b,255))};Rgb.prototype.darker=function(b){if(this.transparent)return this;if(typeof b=="undefined")b=5;var c=Math.round(this.red*(100-b)/100),d=Math.round(this.green*(100-b)/100);b=Math.round(this.blue*(100-b)/100);return new Rgb(c,d,b)};
Rgb.prototype.toHex=function(){return this.transparent?"":twoDigit(toHex(this.red))+twoDigit(toHex(this.green))+twoDigit(toHex(this.blue))};Rgb.prototype.toString=function(){return this.transparent?"transparent":"#"+this.toHex()};
function hexToRgb(b){if(b=="transparent"||b==null)return new Rgb("transparent");if(b.startsWith("0x"))b=b.substr(2);if(b.startsWith("#"))b=b.substr(1);b=b.toUpperCase();var c,d;if(b.length==6){c=hexToNum(b.substr(0,2));d=hexToNum(b.substr(2,2));b=hexToNum(b.substr(4,2))}else if(b.length==3){c=hexToNum(b.substr(0,1)+b.substr(0,1));d=hexToNum(b.substr(1,1)+b.substr(1,1));b=hexToNum(b.substr(2,1)+b.substr(2,1))}else throw new Error('Illegal call to hexToRgb( color ) ("'+b+"\"). Parameter 'color' is expected to be 'transparent' or a hexadecimal value in the formats '0xE0FFA8', '0xFFF', '#EF9090', '#888', 'A8CEF3' or 'FFF'.");
return new Rgb(c,d,b)}function hexToNum(b,c){if(typeof c=="undefined")c=1;var d=b.substr(b.length-1).toUpperCase();if(b.length>1)return hexToNum(b.substr(0,b.length-1),c*16)+hexToNum(d,c);switch(d){case "A":return 10*c;case "B":return 11*c;case "C":return 12*c;case "D":return 13*c;case "E":return 14*c;case "F":return 15*c;default:return parseInt(d)*c}}
function toHex(b){if(typeof b!="number")throw new Error('Illegal call to toHex( number ) ("'+b+"\"). Parameter 'number' is not a number.");if(b<10)return String(b);switch(b){case 10:return"A";case 11:return"B";case 12:return"C";case 13:return"D";case 14:return"E";case 15:return"F"}return toHex(Math.floor(b/16))+toHex(b%16)}function fillOut(b){return Number(b)<10?"0"+String(b):String(b)}
function isEmail(b){return(new RegExp("^([\\w-][\\w-\\.]*)[\\w-]@([\\w-]+(\\.[\\w-]+)*)\\.(\\w{2,4})$","gi")).test(b)}function isURL(b){return Url.isValid(b)}function flashString(b){b=b.replace(/\%/g,"%25");b=b.replace(/\&amp;/g,"%26");b=b.replace(/\&/g,"%26");return b=b.replace(/\+/g,"%2B")}
function withZeros(b,c){var d="";if(!(new RegExp("^-?\\d+(\\.\\d+)?$","gi")).test(b))return false;if(b.startsWith("-")){b=b.substr(1);d="-"}if(b.indexOf(".")>-1){for(;b.endsWith("0");)b=b.substr(0,b.length-1);if(b.endsWith("."))b=b.substr(0,b.length-1)}if(b.startsWith("0")){for(;b.startsWith("0");)b=b.substr(1);if(b.startsWith("."))b="0"+b;if(b.length==0)b="0"}return parseFloat(d+b)==c}
function isNumeric(b){b=new String(b);if(b.indexOf(",")>-1&&b.indexOf(".")>-1)if(b.indexOf(",")>b.indexOf("."))b=b.replace(/\./gi,"");else if(b.indexOf(",")<b.indexOf("."))b=b.replace(/\,/gi,"");b=b.replace(/\,/gi,".");return withZeros(b,parseFloat(b))}function toNumber(b){if(b.indexOf(",")>-1&&b.indexOf(".")>-1)if(b.indexOf(",")>b.indexOf("."))b=b.replace(/\./gi,"");else if(b.indexOf(",")<b.indexOf("."))b=b.replace(/\,/gi,"");b=b.replace(/\,/gi,".");return parseFloat(b)}
function include(b){var c=document.getElementsByTagName("head")[0],d=c?c.getElementsByTagName("script"):null;if(!c)return false;if(d)for(var e=0;e<d.length;e++)if(d[e].getAttribute("src")==b)return false;d=document.createElement("script");d.setAttribute("language","javascript");d.setAttribute("type","text/javascript");d.setAttribute("src",b);c.appendChild(d);return true}
function filterHeaders(b){b=b.replace(/\t*<\![^>]+>(\r\n)?/gi,"");b=b.replace(/\t*<\/?html[^>]*>(\r\n)?/gi,"");if(b.indexOf('<img id="imgBack')>-1){b=b.split("\r\n");for(var c=0;c<b.length;c++)if(b[c].trim().startsWith('<img id="imgBack"')){b[c]="";c=b.length}else b[c]="";b=b.join("\r\n").trimEnd().trimStart("\r\n")}return b=b.replace(/\t*<\/body>(\r\n)?/gi,"")}
function getHtml(b,c){if(b&&typeof b.innerHTML!="undefined"){if(typeof c.request=="undefined")c=new Url(c);c=c.add("rnd",rndString());c=c.request();if(String(c).trim()!=""&&c==false||String(c).toLowerCase()=="false")return false;b.innerHTML=filterHeaders(c);return true}else throw new Error('Illegal call to getHtml( element, url ). Parameter "element" is not a valid Html object.');}
function htmlSize(b){if(typeof b=="string")b=Html.get(b);if(typeof b=="undefined"||b==null)throw new Error("Illegal argument. First argument is undefined or element not found ("+valueString(b)+").");b.size=new Size(b.offsetWidth-measure(b,"margin-left")-measure(b,"border-left-width")-measure(b,"padding-left")-measure(b,"padding-right")-measure(b,"border-right-width")-measure(b,"margin-right"),b.offsetHeight-measure(b,"margin-top")-measure(b,"border-top-width")-measure(b,"padding-top")-measure(b,"padding-bottom")-
measure(b,"border-bottom-width")-measure(b,"margin-bottom"));return b.size}function isScrolling(b){if(typeof b=="undefined"||b==null)return false;else{var c=Element.getStyle(b,"overflow");if(isIE&&Element.getStyle(b,"overflowY")!="hidden")c="auto";return b.offsetHeight<b.scrollHeight&&c!="hidden"?true:false}}
function xFind(b,c){c=String(c).toLowerCase().split("/");for(var d=0;d<c.length&&b!=null;d++){for(var e=null,f=c[d].contains("[")?c[d].split("[")[0]:c[d],g=c[d].contains("[")?c[d].split(/[\[\]]/)[1]:1,h=0;h<b.childNodes.length&&g&&e==null;h++){var i=b.childNodes[h];if(i.nodeType==1&&(f=="*"||i.tagName.toLowerCase()==f)){g--;if(g==0)e=i}}b=e}return b}function getParent(b,c){if(typeof b=="string")b=Html.get(b);if(typeof c=="undefined")c=1;for(;b&&c--;)b=b.parentNode;return b}var szPage=1,szWindow=2;
function getSize(b){if(document.body){if(pageSize==null||winSize==null){var c,d,e,f;if(window.innerHeight&&window.scrollMaxY){e=document.body.scrollWidth;f=window.innerHeight+window.scrollMaxY}else if(document.body.scrollHeight>document.body.offsetHeight){e=document.body.scrollWidth;f=document.body.scrollHeight}else{e=document.body.offsetWidth;f=document.body.offsetHeight}if(self.innerHeight){c=self.innerWidth;d=self.innerHeight}else if(document.documentElement&&document.documentElement.clientHeight){c=
document.documentElement.clientWidth;d=document.documentElement.clientHeight}else if(document.body){c=document.body.clientWidth;d=document.body.clientHeight}pageHeight=f<d?d:f;if(e<c){pageWidth=c;if(f>d)pageWidth-=18}else pageWidth=e;pageSize=new Size(pageWidth,pageHeight);winSize=new Size(c,d)}}else return null;switch(b){case szPage:return pageSize;case szWindow:return winSize;default:return[pageSize,winSize]}}
function measure(b,c){if(c==null||c=="")return 0;c=String(c);c=Element.getStyle(b,c);var d=parseFloat(c),e=0;if(isNaN(d))d=0;if(String(c).endsWith("%"))e=Math.round(b.offsetWidth*d/100,0);else if(String(c).endsWith("px"))e=d;return e}
function getLeft(b){if(b&&b!=document.body){var c=Element.getStyle(b,"position");return c=="absolute"||c=="relative"?b.offsetLeft:b.offsetLeft+getLeft(b.offsetParent)-b.scrollLeft}else return b&&browser==browsers.IE&&b==document.body?measure(document.body,"margin-left"):0}
function getTop(b){if(b&&b!=document.body){var c=Element.getStyle(b,"position");return c=="absolute"||c=="relative"?b.offsetTop:b.offsetTop+getTop(b.offsetParent)-b.scrollTop}else return b&&browser==browsers.IE&&b==document.body?measure(document.body,"margin-top"):0}function getPos(b){return new Point(getLeft(b),getTop(b))}Point=function(b,c){this.Class="Point";this.left=typeof b!="undefined"?b:0;this.top=typeof c!="undefined"?c:0};
Point.prototype.toString=function(){return"Point("+this.left+", "+this.top+")"};Size=function(b,c){this.Class="Size";this.width=typeof b!="undefined"?b:0;this.height=typeof c!="undefined"?c:0};Size.prototype.toString=function(){return"Size("+this.width+", "+this.height+")"};
Array.contains=function(b,c){if(b==null||typeof b.length=="undefined")throw new Error("Illegal call to Array.indexOf(). First parameter is not an array.");for(var d=0;d<b.length;d++)if(c instanceof RegExp){if(String(b[d]).search(c)>-1)return true}else if(c instanceof Date){if(c.isSameDate(b[d]))return true}else if(b[d]==c)return true;return false};Array.isArray=function(b){if(b==null)return false;return b instanceof Array};
Array.indexOf=function(b,c,d,e){if(b==null||typeof b.length=="undefined")throw new Error("Illegal call to Array.indexOf(). First parameter is not an array.");d=typeof d=="undefined"?0:parseInt(d);if(isNaN(d)||d<0)d=0;e=typeof e=="undefined"?b.length:parseInt(e);if(isNaN(e)||e>b.length)e=b.length;for(d=d;d<e;d++)if(c instanceof RegExp){if(String(b[d]).search(c)>-1)return true}else if(c instanceof Date){if(c.isSameDate(b[d]))return d}else if(b[d]==c)return d;return-1};a=Array.prototype;
a.add=function(b){var c=this.length;this[this.length]=b;return c};a.clear=function(){this.length=0};a.contains=function(b){return Array.contains(this,b)};a.insert=function(b,c){if(b<0)throw new Error("Illegal argument. Index out of range ("+b+").");if(b>this.length)b=this.length;for(var d=this.length;d>b;d--)this[d]=this[d-1];this[b]=c};a.insertAfter=function(b,c){c=this.indexOf(c);if(c==-1)throw new Error("Illegal argument. Given element is not contained by the array.");this.insert(c+1,b)};
a.insertBefore=function(b,c){c=this.indexOf(c);if(c==-1)throw new Error("Illegal argument. Given element is not contained by the array.");this.insert(c,b)};a.indexOf=function(b,c,d){return Array.indexOf(this,b,c,d)};a.moveTo=function(b,c){var d=this.indexOf(b);if(d!=c){d>-1&&this.remove(d);this.insert(c,b)}};
a.remove=function(b){if(typeof b=="number"){for(b=b;b<this.length-1;b++)this[b]=this[b+1];this.length--}else{b=this.indexOf(b);if(b>-1)this.remove(b);else throw new Error("Illegal argument. Given element is not contained by the array.");}};NumberFormat=function(b,c,d){this.decimalSeparator=b;this.groupingSeparator=c;this.currencySymbol=d};
Number.prototype.fillOut=function(b){if(isNaN(this)||!isFinite(this))return String(this);if(typeof b=="undefined")b=2;for(var c=String(this);c.length<b;)c="0"+c;return c};
Number.prototype.formatString=function(b){if(b=="C"||b=="c")return this.formatString(Number.formatInfo.currencySymbol+" ,##0.00");else if(b=="D"||b=="d")return this.formatString("0");else if(b=="N"||b=="n")return this.formatString(",##0.00");else if(b=="P"||b=="p")return this.formatString(",##0.00%");else if(b==null||b==""||typeof b=="undefined")return String(this).replace(".",Number.formatInfo.decimalSeparator);else b=String(b);var c=String(this),d=b,e=c.split(/\./gi),f=b.indexOf(",")>-1,g=this<
0;b=b.replace(/,/gi,"");b=b.split(/\./gi);if(b[0].match(/0#/gi))throw new Error("Illegal format in call to \"formatString\". '#' encountered after '0' and before the decimal separator.");if(b.length>1&&b[1].match(/#0/gi))throw new Error("Illegal format in call to \"formatString\". '#' encountered before '0' and after the decimal separator.");if(b.length>2)throw new Error('Illegal format in call to "formatString". Multiple use of decimal separator.');if(!d.endsWith("."))if(b.length==1)e=String(Math.round(c)).split(".");
else if(b[1].length>0){e=b[1].search(/[^#0]/g);if(e==-1)e=b[1].length;e=String(Math.round(c*Math.pow(10,e))/Math.pow(10,e)).split(".")}c=g?e[0].substr(1):e[0];d=b[0].replace(/^[^0]*(0+)/gi,"$1");if(d.length>c.length)c=d.substr(0,d.length-c.length)+c;if(f){f=c;c="";for(d=f.length-1;d>=0;d-=3)c=d-2>=0?Number.formatInfo.groupingSeparator+f.substr(d-2,3)+c:f.substr(0,d+1)+c;if(c.startsWith("."))c=c.substr(1)}f=b[0].search(/[0#,\.]/);if(f>0)c=b[0].substr(0,f)+c;if(b.length>1){c+=Number.formatInfo.decimalSeparator;
if(e.length>1){c+=e[1];if(b.length>1){f=b[1].replace(/([#0])/g,"$1");if(f.length>e[1].length)c+=f.substr(f.length-e[1].length);e=Math.min(e[1].length,b[1].search(/[^#0]/g));if(e>-1)c+=b[1].substr(e)}}else if(b.length>1)c+=b[1]}b=new RegExp(RegExp.escape(Number.formatInfo.decimalSeparator)+"#+","g");if(b.test(c))c=c.replace(b,"");c=c.replace(/#/gi,"");if(c.endsWith(Number.formatInfo.decimalSeparator))c=c.substr(0,c.length-1);return g?"-"+c:c};
RegExp.escape=function(b){if(b==null||b==""||typeof b=="undefined")return"";b=String(b);b=b.replace(/\\/g,"\\\\");b=b.replace(/\./g,"\\.");b=b.replace(/\^/g,"\\^");b=b.replace(/\$/g,"\\$");b=b.replace(/\?/g,"\\?");b=b.replace(/\*/g,"\\*");b=b.replace(/\+/g,"\\+");b=b.replace(/\|/g,"\\|");b=b.replace(/\(/g,"\\(");b=b.replace(/\)/g,"\\)");b=b.replace(/\{/g,"\\{");b=b.replace(/\}/g,"\\}");b=b.replace(/\[/g,"\\[");return b=b.replace(/\]/g,"\\]")};var regExp={escape:function(b){return RegExp.escape(b)}};
a=String.prototype;a.capitalize=function(){return this.substr(0,1).toUpperCase()+this.substr(1)};a.coalesce=function(){if(this!="")return this;for(var b=0;b<arguments.length;b++)if(arguments[b])return arguments[b];return""};a.contains=function(){for(var b=0;b<arguments.length;b++)if(this.indexOf(arguments[b])>-1)return true;return false};a.decapitalize=function(){return this.substr(0,1).toLowerCase()+this.substr(1)};a.endsWith=function(b){return this.substr(this.length-b.length)==new String(b)};
a.htmlDecode=function(){var b=String(this);b||(b="");b=b.replace(/\&amp;/gi,"&");for(var c=0;c<charCodes.length;c++){var d=charCodes[c];b=b.replace(new RegExp(RegExp.escape(specialChar[d-160]),"g"),String.fromCharCode(d))}b=b.replace(/&quot;/gi,'"');b=b.replace(/&lt;/gi,"<");return b=b.replace(/&gt;/gi,">")};
a.htmlEncode=function(){var b=String(this);b||(b="");b=b.replace(/\&/gi,"&amp;");for(var c=0;c<charCodes.length;c++){var d=charCodes[c],e=specialChar[d-160];b=b.replace(new RegExp(String.fromCharCode(d),"g"),e)}b=b.replace(/\"/gi,"&quot;");b=b.replace(/\</gi,"&lt;");return b=b.replace(/\>/gi,"&gt;")};a.indent=function(b){var c="\r\n";if(typeof b=="undefined")b=1;for(var d=0;d<b;d++)c+="\t";return this.replace(/\r\n(\t*<)/gi,c+"$1")};
a.innerTrim=function(){for(var b=new String(this);b.contains("  ");)b=b.replace(/ {2}/gi," ");return b};a.insert=function(b,c){var d=new String(this);if(b>0)d=this.substr(0,b);d+=c;if(b<this.length)d+=this.substr(b,this.length-b);return d};a.lowerFirst=function(){return this.substr(0,1).toLowerCase()+this.substr(1)};a.reverse=function(){for(var b="",c=0;c<this.length;c++)b+=this.substr(this.length-c-1,1);return b};a.shortenLeft=function(b){return this.substr(b)};
a.shortenRight=function(b){return this.substr(0,this.length-b)};a.startsWith=function(b){return this.substr(0,b.length)==new String(b)};a.toJs=function(){var b=this.replace(/\\/gi,"\\\\");b=b.replace(/\"/gi,'\\"');b=b.replace(/\r/gi,"\\r");b=b.replace(/\n/gi,"\\n");b=b.replace(/\t/gi,"\\t");return'"'+b+'"'};
a.trim=function(b){var c=new String(this);if(arguments.length==0){c=c.replace(/^\s*/gi,"");c=c.replace(/\s*$/gi,"")}else{var d=new RegExp("^["+RegExp.escape(b)+"]*","gi"),e=new RegExp("["+RegExp.escape(b)+"]*$","gi");c=c.replace(d,"");c=c.replace(e,"")}return c};a.trimEnd=function(b){var c=new String(this);return c=typeof b=="undefined"?c.replace(/\s*$/gi,""):c.replace(new RegExp("["+RegExp.escape(b)+"]*$","gi"),"")};
a.trimStart=function(b){var c=new String(this);return c=typeof b=="undefined"?c.replace(/^\s*/gi,""):c.replace(new RegExp("^["+RegExp.escape(b)+"]*","gi"),"")};a.unindent=function(b){var c="\r\n";if(typeof b=="undefined")b=1;for(var d=0;d<b;d++)c+="\t";return this.replace(new RegExp(c),"\r\n")};a.upperFirst=function(){return this.substr(0,1).toUpperCase()+this.substr(1)};TUser=function(b,c,d,e){this.Class="TUser";this.ID=b;this.fullname=c;this.username=d;this.eMail=e};
TUser.prototype.toJS=function(){return"new TUser( "+valueString(this.ID)+", "+valueString(this.fullname)+", "+valueString(this.username)+", "+valueString(this.eMail)+")"};
TUser.prototype.toXML=function(b){if(typeof b=="undefined")b="user";var c="\r\n<"+b;if(String(this.ID)!="null")c+=' ID="'+this.ID+'"';c+=">";if(this.fullname)c+="\r\n\t<fullname>"+this.fullname+"</fullname>";if(this.username)c+="\r\n\t<username>"+this.username+"</username>";if(this.eMail)c+="\r\n\t<eMail>"+this.eMail+"</eMail>";c+="\r\n</"+b+">";return c};
Url=function(b){var c=null;this.Class="Url";this.disposed=false;this.onreadystagechange=this.HTTP=null;this.index=Url.all.add(this);c=typeof b=="undefined"?String(document.location):String(b).replace(/\&amp;/gi,"&");if(Url.unload==null)Url.unload=addEvent(window,"unload","Url.dispose();");this.url=function(d){if(typeof d=="undefined")return c;else c=d}};a=Url.prototype;
a.add=function(b,c){var d=this.url();if(c==null||typeof c=="undefined")return this.remove(b);else{if(typeof c.age!="undefined")c=c.formatString("g?");c=encodeURI(c).replace(/[&]/gi,"%26").replace(/\+/g,"%2B");if(d.search(new RegExp("([?&])("+b+"=[^&#]*)","gi"))>-1)d=d.replace(new RegExp("([?&])("+b+"=[^&#]*)","gi"),"$1"+b+"="+c);else{var e=null;if(d.indexOf("#")>-1){e=d.substr(d.indexOf("#"));d=d.substr(0,d.indexOf("#"))}d+=d.indexOf("?")>-1?"&"+b+"="+c:"?"+b+"="+c;if(e)d+=e}}return new Url(d)};
a.async=function(b,c,d){if(typeof d=="string")this.onreadystatechange=new Function("HTTP",d);else if(typeof d=="function")this.onreadystatechange=d;if(this.onreadystatechange!=null&&typeof this.onreadystatechange!="function")throw new Error("Illegal assignment to Url.onreadystatechange. Property is not a function.");if(typeof b=="undefined")b="GET";if(typeof c=="undefined")c=null;this.HTTP=new XMLHttpRequest;if(this.onreadystatechange!=null)this.HTTP.onreadystatechange=new Function("Url.all["+this.index+
"].loaded();");this.HTTP.open(b.toUpperCase(),this.add("rnd",rndString()));this.HTTP.setRequestHeader("snakeware-ajax","true");b.toUpperCase()=="POST"&&this.HTTP.setRequestHeader("Content-Type","application/x-www-form-urlencoded");this.HTTP.send(c)};a.current=function(){return new Url(String(document.location))};a.dispose=function(){if(!this.disposed){this.onreadystagechange=this.HTTP=null;this.disposed=true}};
a.get=function(b){var c=this.url();b=c.replace(new RegExp(".*[?&]"+b+"=([^&#]*).*","gi"),"$1");return b=b==c?null:decodeURI(b).replace(/%26/gi,"&").replace(/%2B/gi,"+")};a.filter=function(){for(var b=new Url(this.url()),c=0;c<arguments.length;c++)b=b.remove(arguments[c]);return b};a.filterAllBut=function(){for(var b=new Url(this.url().replace(new RegExp(Url.regex),"$1$4")),c=0;c<arguments.length;c++)b=b.add(arguments[c],this.get(arguments[c]));return b};
a.isSame=function(b){Url.isUrl(b)||(b=new Url(b));var c=this.page(),d=b.page();if(c!=null||d!=null){if(c==null&&d!=null)return false;if(c!=null&&d==null)return false;if(c.toLowerCase()!=d.toLowerCase())return false}c=this.removeServer().replacePage("").url().substr(1).split("&");for(d=0;d<c.length;d++)if(c[d].contains("="))c[d]=c[d].substr(0,c[d].indexOf("="));for(d=0;d<c.length;d++)if(b.get(c[d])!=this.get(c[d]))return false;return true};a.loaded=function(){this.HTTP.readyState==4&&this.onreadystatechange(this.HTTP)};
a.page=function(){var b=this.url().replace(new RegExp(Url.regex),"$4");if(b=="")b=null;return b};a.query=function(){var b=this.server();b=b!=null?b+this.page():this.page();b=this.toString().replace(b,"");if(b.startsWith("?"))b=b.substr(1);return b};
a.remove=function(b){var c=this.url();if(b=="#"){if(c.indexOf("#")>-1)c=c.substr(c.indexOf("#"));return new Url(c)}c=c.replace(new RegExp("([?&])"+b+"=[^&#]*","gi"),"$1");c=c.replace(/\?&/gi,"?");c=c.replace(/&&/gi,"&");c=c.replace(/&$/gi,"");c=c.replace(/\?$/gi,"");return new Url(c)};a.removeServer=function(){var b=this.server();return b!=null?new Url(this.url().replace(b,"")):new Url(this.url())};
a.replacePage=function(b,c){var d=rewriting,e=this.url(),f=this.page();if(typeof c=="undefined")c=false;if(c)d=false;if(f!=null&&f.endsWith(".aspx")||!d){if(f==null){e=e.replace(new RegExp(Url.regex),"$1/"+b+"$9");e=e.replace("//"+b,"/"+b);if(e.startsWith("/"+b))e=e.substr(1);return new Url(e)}return new Url(e.replace(f,b))}else return this.add("use",b.replace(".aspx",""))};
a.request=function(b,c,d,e){if(typeof b=="undefined")b="GET";if(typeof c=="undefined")c=null;if(typeof d=="undefined")d=false;var f=this,g=new XMLHttpRequest;if(c==null&&b.toUpperCase()=="POST"){c=this.server();f=new Url(c!=null?c+this.page():this.page());c=this.query()}g.open(b.toUpperCase(),f.add("rnd",rndString()),false);g.setRequestHeader("snakeware-ajax","true");b.toUpperCase()=="POST"&&g.setRequestHeader("Content-Type","application/x-www-form-urlencoded");g.send(c);if(g.status==200)return d?
g.responseXML:g.responseText;else{if(e||typeof e=="undefined")this.showError(g);return false}};a.server=function(){var b=this.url().replace(new RegExp(Url.files),"$1");if(b=="")b=null;return b};a.showError=function(b){if(this.HTTP!=null&&typeof b=="undefined")b=this.HTTP;alertWin(b.responseText)};a.toExternal=function(){var b=this.server(),c=this.url();if(b==null)c=Url.current.server()+c;return new Url(c)};a.toString=function(){return this.url()};Url.all=[];Url.current=new Url;Url.disposed=false;
Url.files=/^(https?:\/\/(localhost(\:\d+)?\/)?[^\/\?]+[\/]?)?(([^\/\.]+\/)*[^\?]*?)?(\?.*)?$/gi;Url.local=new RegExp("^([a-zA-Z0-9\\-]+|(http://)?localhost:\\d+)?(/\\S*)?$","gi");Url.regex=/^(https?:\/\/(localhost(\:\d+)?\/)?[^\/\?]+[\/]?)?(([^\/\.]+\/)*([^\.\?]+(\.(as[ph]x?|html?|php?))?)?)?(\?.*)?$/gi;Url.relative=new RegExp("^(/\\S*)?$","gi");Url.unload=null;
Url.valid=new RegExp("^(https?\\://)?((([a-zA-Z0-9][a-zA-Z0-9\\-]{1,62}[a-zA-Z0-9].)*([a-zA-Z0-9][a-zA-Z0-9\\-]{1,58}[a-zA-Z0-9])(\\.[a-zA-Z]{2,4}))|(\\d{1,3}(\\.\\d{1,3}){3}))(/\\S*)?$","gi");Url.dispose=function(){if(!Url.disposed){for(var b=0;b<Url.all.length;b++){Url.all[b].dispose();Url.all[b]=null}Url.all=[];Url.disposed=true;Url.regex=null}};Url.isLocal=function(b){if(b==null)return false;if(Url.isUrl(b))b=b.toString();return(new RegExp(Url.local)).test(b)};
Url.isRelative=function(b){if(b==null)return false;if(Url.isUrl(b))b=b.toString();return(new RegExp(Url.relative)).test(b)};Url.isUrl=function(b){return Object.getClass(b)=="Url"};Url.isValid=function(b){if(b==null)return false;if(Url.isUrl(b))b=b.toString();var c=b.replace(Url.valid,"$6");if(c!=""&&c!=null){c=c.split(".");for(var d=0;d<c.length;d++)if(Number(c[d])>255)return false}return(new RegExp(Url.valid)).test(b)};
Object.getClass=function(b){if(b==null)return null;return typeof b!="undefined"&&typeof b.Class!="undefined"?b.Class:typeof b};
var Log={active:false,Class:"Log",included:false,doWrite:function(){},error:function(b){if(b.description)Log.write("ERROR",b.description);else b.message?Log.write("ERROR",b.message):Log.write("ERROR",b)},write:function(){if(Log.active)if(!Log.included){var b=(new Url("js/default/log.js")).request();eval(b);Log.included=true;Log.write.apply(this,arguments)}}},Cookies={exists:function(b){return Cookies(b)!=null},get:function(b){b=getCookie(b);if(b==null)return b;else{b=String(b).split("|~~|");var c=
b.length>1?parseInt(b[1]):dtString;return b.length?convert(b[0],c):null}},remove:function(b){removeCookie(b)},set:function(b,c,d){if(c==null&&String(c)=="null")removeCookie(b);else{if(typeof d=="undefined")d=typeof c=="boolean"?dtBoolean:typeof c=="number"?String(c).contains(".")?dtDouble:dtInteger:typeof c=="object"&&typeof c.formatString!="undefined"?dtDateTime:dtString;switch(d){case dtBoolean:c=c?"true":"false";break;case dtDateTime:c=c.formatString("g");break;default:c=String(c)}c+="|~~|"+d;
setCookie(b,c)}}},Html={addClass:function(b,c){Element.addClassName(b,c)},blur:function(b){Element.removeClassName(b,"focused")},disable:function(b){Element.addClassName(b,"disabled")},enable:function(b){Element.removeClassName(b,"disabled")},find:function(b,c,d){if(typeof d=="undefined")d=false;if(b&&typeof b.childNodes!="undefined"){for(var e=0;e<b.childNodes.length;e++){var f=b.childNodes[e];if(c==ntText){if(typeof f.data!="undefined"&&f.data!=""&&f.data!=null)return f}else if(f.nodeType==c)return f}if(d)for(e=
0;e<b.childNodes.length;){f=b.childNodes[e];return Html.find(f,c,true)}}return null},findAll:function(b,c,d,e){if(typeof e=="undefined")e=[];if(typeof d=="undefined")d=false;if(b&&typeof b.childNodes!="undefined")for(var f=0;f<b.childNodes.length;f++){var g=b.childNodes[f];if(c==ntText)typeof g.data!="undefined"&&g.data!=""&&g.data!=null&&e.add(g);else g.nodeType==c&&e.add(g);if(d)e=Html.findAll(g,c,true,e)}return e},focus:function(b){Element.addClassName(b,"focused")},get:function(b){if(arguments.length>
1){for(var c=0;c<arguments.length;c++){var d=Html.get(arguments[c]);if(d)return d}return null}else return typeof b=="string"?document.getElementById(b):typeof b=="undefined"?null:b},getLineHeight:function(b){if(browser==browsers.IE){var c=b.parentNode.appendChild(document.createElement(b.nodeName));c.innerHTML="testje";c.style.border="0px solid";c.style.height="auto";c.style.margin="0px";c.style.padding="0px";c.style.width="1000px";c.rows=1;b=c.clientHeight;c.parentNode.removeChild(c);return b}return parseInt(Element.getStyle(b,
"line-height"))},getText:function(b){b=Html.findAll(b,ntText,true);for(var c="",d=0;d<b.length;d++)c+=b[d].data;return c.trim()},hasClass:function(b,c){return Element.hasClassName(b,c)},moveBottom:function(b){if(b.nextSibling){b.parentNode.appendChild(b);return true}return false},moveDown:function(b){if(b.nextSibling){b.nextSibling.nextSibling?b.parentNode.insertBefore(b,b.nextSibling.nextSibling):b.parentNode.appendChild(b);return true}return false},moveTop:function(b){if(b.previousSibling){b.parentNode.insertBefore(b,
b.parentNode.firstChild);return true}return false},moveUp:function(b){if(b.previousSibling){b.parentNode.insertBefore(b,b.previousSibling);return true}return false},remove:function(b){b.parentNode&&b.parentNode.removeChild(b)},removeClass:function(b,c){Element.removeClassName(b,c)},setText:function(b,c){if(c==null)c="";if(typeof c!="string")c=String(c);var d=Html.find(b,ntText);if(d!=null)d.data=c;else b.insertBefore(document.createTextNode(c),b.firstChild)},toAttrib:function(b){if(b!=null){for(b=
String(b);b.indexOf("&amp;")>-1;)b=b.replace(/\&amp;/gi,"&");b=b.replace(/\&/gi,"&amp;");b=b.replace(/\"/gi,"&quot;");b=b.replace(/</gi,"&lt;");b=b.replace(/>/gi,"&gt;")}else b="";return b},toHtml:function(b){if(b!=null){b=String(b);b=b.htmlEncode();b=b.replace(/\r?\n/gi,"<br/>");b=b.trim()}else b="";return b},toText:function(b){var c;if(b!=null){b=String(b);b=b.replace(/[\r?\n]/gi,"");b=b.replace(/<p>&nbsp;<\/p>/gi,"<p></p>");b=b.replace(/<br\/?>/gi,"\r\n");b=b.replace(/<\/p>/gi,"\r\n");b=b.replace(/<\/h\d>/gi,
"\r\n");b=b.replace(/<\/?[^>]+>/gi,"");for(var d=0;d<charCodes.length;d++){c=new RegExp(RegExp.escape(specialChar[charCodes[d]-160]),"g");b=b.replace(c,String.fromCharCode(charCodes[d]))}c=new RegExp("&#(\\d{3});","g");for(d=b.match(c);d;){var e=parseInt(d[0].replace("&#",""));b=b.replace(d[0],String.fromCharCode(e));d=b.match(c)}b=b.trim()}return b}},Counter={changes:[],element:null,func:null,max:99,min:1,startValue:null,stop:false,timer:null,action:function(b){clearTimeout(Counter.timer);var c=
Number(Counter.element.value);if(c+b>=this.min&&c+b<=this.max){if(!Counter.stop||Counter.startValue==c)Counter.element.value=c+b;if(!Counter.stop)Counter.timer=setTimeout("Counter.action( "+b+");",200)}else Counter.stop=true;Counter.stop&&Counter.stopped()},end:function(){Counter.stop=true},init:function(b,c){if(typeof c=="undefined")c=null;if(b&&!b.chEvent&&c){if(typeof c=="string")c=new Function("value",c);var d=Counter.changes.length;Counter.changes.add({element:b,func:c});b.onchange=null;b.removeAttribute("onchange");
b.chEvent=addEvent(b,"change","Counter.onChange("+d+");");browser!=browsers.IE&&Counter.onChange(d)}},onChange:function(b){if(!(b>=Counter.changes.length)){var c=Counter.changes[b].element;b=Counter.changes[b].func;typeof c.field!="undefined"&&c.field.value(c.value);if(b!=null){c=convert(c.value,dtDouble);b(c)}}},start:function(b,c,d){if(typeof b!="string")b=xFind(b.parentNode,"input").id;if(typeof c=="undefined")c=1;else if(Number(c)==NaN)c=1;else if(c>1)c=1;else if(c<-1)c=-1;if(typeof d=="undefined")d=
null;if(Counter.timer==null){if(typeof d=="string")d=new Function("value",d);b=Html.get(b);Counter.func=d;Counter.stop=false;Counter.element=b;Counter.startValue=Number(b.value);Counter.timer=setTimeout("Counter.action( "+c+" );",100);if(!b.field&&!b.chEvent&&d){c=Counter.changes.length;Counter.changes.add({element:b,func:d});b.onchange=null;b.removeAttribute("onchange");b.chEvent=addEvent(b,"change","Counter.onChange( "+c+" );")}}},stopped:function(){if(Counter.timer!=null){clearTimeout(Counter.timer);
var b=Counter.element,c=Counter.func;Counter.element=null;Counter.func=null;Counter.startValue=null;Counter.timer=null;typeof b.field!="undefined"&&b.field.value(b.value);c!=null&&c(b.value)}},unload:function(){Counter.stopped();for(var b=0;b<Counter.changes.length;b++)Counter.changes[b].element.chEvent=null;Counter.changes.clear()}};addEvent(window,"unload","Counter.unload( event );");
var Flipbook={open:function(b,c,d){if(typeof c=="undefined")c=800;if(typeof d=="undefined")d=600;b=(new Url(server+"misc/flipbook.aspx")).add("steID",steID).add("itmID",b);c=window.open(b,"frmFlipbook","menubar=0,location=0,toolbar=0,scrollbars=0,resizable=0,status=0,width="+c+",height="+d);c.opener=window;c&&c.focus()}};

