﻿var browserIsIE=(navigator.appName=="Microsoft Internet Explorer");var browserIsOpera=(navigator.userAgent.search(/Opera/)!=-1);var browserIsSafari=(navigator.userAgent.search(/Safari/)!=-1);var browserIsNetscape=(!browserIsSafari&&navigator.appName=="Netscape");function operaRedrawPage(){if(browserIsOpera){if(document.body.style.position=="static"){document.body.style.position="relative"}else{document.body.style.position="static"}}}function MM_findObj(f,e){var c,b,a;if(!e){e=document}if((c=f.indexOf("?"))>0&&parent.frames.length){e=parent.frames[f.substring(c+1)].document;f=f.substring(0,c)}if(!(a=e[f])&&e.all){a=e.all[f]}for(b=0;!a&&b<e.forms.length;b++){a=e.forms[b][f]}for(b=0;!a&&e.layers&&b<e.layers.length;b++){a=MM_findObj(f,e.layers[b].document)}if(!a&&e.getElementById){a=e.getElementById(f)}return a}function MM_showHideLayers(){var c,e,a,d,b=MM_showHideLayers.arguments;for(c=0;c<(b.length-1);c+=2){if((d=MM_findObj(b[c]))!=null){a=b[c+1];if(d.style){d=d.style;a=(a=="show")?"visible":(a=="hide")?"hidden":a}d.visibility=a}}}function MM_toggleLayers(){var c,e,a,d,b=MM_toggleLayers.arguments;for(c=0;c<(b.length);c++){if((d=MM_findObj(b[c]))!=null){if(d.style){d=d.style;a=(d.visibility=="hidden")?"visible":"hidden"}d.visibility=a}}}function MM_changeProp(objName,theProp,theValue){var obj=MM_findObj(objName);if(obj&&(theProp.indexOf("style.")==-1||obj.style)){eval("obj."+theProp+"="+theValue)}}function getMousePosX(a){if(browserIsNetscape||browserIsOpera){return a.pageX}else{return window.event.clientX}}function getMousePosY(a){if(browserIsNetscape||browserIsOpera){return a.pageY}else{return window.event.clientY}}function getWindowWidth(){if(window.innerWidth){return window.innerWidth}else{if(document.documentElement&&document.documentElement.clientWidth){return document.documentElement.clientWidth}else{return 0}}}function getWindowHeight(){if(window.innerHeight){return window.innerHeight}else{if(document.documentElement&&document.documentElement.clientHeight){return document.documentElement.clientHeight}else{return 0}}}function repositionTooltip(c){var d=document.getElementById("tooltipcontainer0");var j,f,g,e,p,l;if(browserIsNetscape||browserIsOpera||browserIsSafari){g=0;e=0;p=window.pageXOffset;l=window.pageYOffset}else{if(tooltipOffsetX!=0||tooltipOffsetY!=0){g=0;e=0;p=document.documentElement.scrollLeft;l=document.documentElement.scrollTop}else{g=document.documentElement.scrollLeft;e=document.documentElement.scrollTop;p=0;l=0}}j=getMousePosX(c)+20+g;if(browserIsNetscape){j+=netscapeOffsetX}if(browserIsSafari){j+=p}j+=tooltipOffsetX;f=getMousePosY(c)+5+e;if(browserIsNetscape){f+=netscapeOffsetY}if(browserIsSafari){f+=l}f+=tooltipOffsetY;if(tooltipEdge==TOOLTIP_EDGE_BOTTOM_LEFT){f-=d.cheight}var m=0;var h=0;var a=0;for(b=0;b<3;b++){var o=document.getElementById("tooltip"+b);if(o.style.visibility=="visible"||o.moveIt==true){a++}}for(b=0;b<a;b++){var o=document.getElementById("tooltip"+b);var n=document.getElementById("tooltipcontainer"+b);if(n.firstChild.firstChild.className.match(/sdtooltipextrawideflag/)){o.className="sdtooltip sdtooltipextrawide"}else{if(a<3||getWindowWidth()>1232){o.className="sdtooltip sdtooltipwide"}else{o.className="sdtooltip sdtooltipsmall"}}m+=n.cwidth;if(b>0){m+=16}if(n.cheight>h){h=n.cheight}}if(j+m>getWindowWidth()+g+p-5){j=j-m-50+g+p}if(j<g+p){j=g+p}if(f+h>getWindowHeight()+e+l-20){f=getWindowHeight()-h-25+e+l}if(f<e+l){f=e+l}var b;for(b=0;b<a;b++){var o=document.getElementById("tooltip"+b);var n=document.getElementById("tooltipcontainer"+b);o.style.left=j+"px";o.style.top=f+"px";j+=n.cwidth+16}}var netscapeOffsetX=0;var netscapeOffsetY=0;var tooltipOffsetX=0;var tooltipOffsetY=0;var tooltipEdge=0;var TOOLTIP_EDGE_TOP_LEFT=0;var TOOLTIP_EDGE_BOTTOM_LEFT=1;function displayTooltip(b,l,g,f,h,e,c){if(h!=null){tooltipOffsetX=h}else{tooltipOffsetX=0}if(e!=null){tooltipOffsetY=e}else{tooltipOffsetY=0}if(g!=null){netscapeOffsetX=g}else{netscapeOffsetX=0}if(f!=null){netscapeOffsetY=f}else{netscapeOffsetY=0}if(c!=null){tooltipEdge=c}else{tooltipEdge=TOOLTIP_EDGE_TOP_LEFT}var j=new Array();if(typeof l=="string"){j.push(l)}else{var m=l[0];if(m=="text"){j.push(l[1]);if(typeof pinneditemdata!="undefined"&&l[2]!=null&&l[2]>=0&&l[2]<pinneditemdata.length){var d;for(d=0;d<pinneditemdata[l[2]].length;d++){if(pinneditemdata[l[2]][d]!=null&&pinneditemdata[l[2]][d][4][1]!=l[1]){j.push(pinneditemdata[l[2]][d][4][1])}}}}else{if(m=="render"){j.push('<img src="images/renders/'+l[1]+'" width="'+l[2]+'" height="'+l[3]+'" />')}}}var a;for(a=0;a<j.length;a++){setupSingleTooltip(b,j[a],a)}repositionTooltip(b);for(a=0;a<j.length;a++){MM_showHideLayers("tooltip"+a,"show");document.getElementById("tooltip"+a).moveIt=false}}function setupSingleTooltip(e,b,g){var f=document.getElementById("tooltip"+g);f.style.left="0px";f.style.top="0px";var a=document.getElementById("tooltipcontainer"+g);var d=document.getElementById("tooltipcontent"+g);if(d){a.removeChild(d)}var c=document.createElement("div");c.id="tooltipcontent"+g;c.innerHTML=b;a.appendChild(c);a.cwidth=a.clientWidth;a.cheight=a.clientHeight;f.moveIt=true}function hideTooltip(){MM_showHideLayers("tooltip0","hide");MM_showHideLayers("tooltip1","hide");MM_showHideLayers("tooltip2","hide");tooltipOffsetX=0;tooltipOffsetY=0;netscapeOffsetX=0;netscapeOffsetY=0}function getXmlHttp(){var a=false;if(typeof(XMLHttpRequest)!="undefined"){a=new XMLHttpRequest()}if(!a){try{a=new ActiveXObject("Msxml2.XMLHTTP")}catch(b){try{a=new ActiveXObject("Microsoft.XMLHTTP")}catch(b){a=false}}}return a}function startAJAXRequest(b,c){var a=getXmlHttp();if(a&&b!=null){a.open("GET",b,true);a.onreadystatechange=function(){if(a.readyState==4){if(c){c(a.responseText)}}};a.send(null)}}function startAJAXPostRequest(c,f,e){var b="";var d;for(d=0;d<f.length/2;d++){if(d>0){b=b+"&"}b=b+f[d*2]+"="+f[d*2+1]}var a=getXmlHttp();if(a){a.open("POST",c,true);a.setRequestHeader("Content-Type","application/x-www-form-urlencoded");a.onreadystatechange=function(){if(a.readyState==4){e(a.responseText)}};a.send(b)}}function getListContentTable(){listcontent=document.createElement("table");listcontent.id="listcontent";listcontent.width="100%";listcontent.border=0;listcontent.cellPadding=0;listcontent.cellSpacing=2;return listcontent}function getListContentHeader(a,e,c,g,f){var h=document.createElement("th");if(a==true){h.className="tableheader firstheader"}else{h.className="tableheader"}h.scope="col";h.width=e;var d=document.createElement("a");d.href=c;var b=document.createElement("div");b.appendChild(document.createTextNode(g));if(f==0){b.className="sortasc"}if(f>0){b.className="sortdesc"}d.appendChild(b);h.appendChild(d);return h}function appendMultipleChilds(b,c){var a;for(a=0;a<c.length;a++){if(c[a]!=null){b.appendChild(c[a])}}}function removeAllChilds(a){while(a.firstChild){a.removeChild(a.firstChild)}}function removeFromParent(a){a.parentNode.removeChild(a)}function selectValueInList(c,b){for(i=0;i<c.options.length;i++){var a=c.options[i];if(a.value==b){a.selected=true}else{a.selected=false}}}function getListTableElement(g,f,b,a,e,c){var d=document.createElement("td");d.align=g;d.valign="middle";if(f!=null){d.appendChild(f)}if(b!=null){d.width=b}if(a!=null){d.style.background=a}if(e!=null){d.colSpan=e}if(c!=null){d.rowSpan=c}return d}function getLinkElement(d,c,a,e){if(d==null||d==""){return null}var b=document.createElement("a");b.href=c;if(typeof(d)=="string"){b.appendChild(document.createTextNode(d))}else{b.appendChild(d)}if(e){b.target=e}if(a!=null){a.appendChild(b)}return b}function getTextInputField(c,a){var b=document.createElement("input");b.id=c;b.name=c;b.type="text";b.size=a;return b}function getButton(c,a){var b=document.createElement("input");b.type="button";b.value=c;if(a!=null){b.onclick=a}return b}function getTable(b,a,e,d){var c=document.createElement("table");c.width=b;c.border=a;c.cellSpacing=e;c.cellPadding=d;return c}function getSpan(b,c){var a=document.createElement("span");a.id=c;a.className=b;return a}function getCheckbox(f,e,b,c,a){var d=document.createElement("input");d.type="checkbox";d.id=f;d.name=f;d.value=e;d.defaultChecked=b;d.checked=c;if(a){d.onclick=a}return d}function getDropsite(a){switch(a){case 1:return"item";case 2:return"spell";case 3:return"itemset";case 4:return"npc";case 5:return"quest";case 6:return"object";case 7:return"zone";case 8:return"faction";case 9:return"achievement"}}function displayLoadingScreen(){var d=document.getElementById("listbody");var h=document.getElementById("listcontent");if(h!=null){d.removeChild(h)}var c=document.getElementById("listheader");var b=document.getElementById("listfooter");if(c!=null){removeAllChilds(c.firstChild.firstChild)}if(b!=null){removeAllChilds(b.firstChild.firstChild)}h=getListContentTable();var f=document.createElement("tr");var a=document.createElement("td");var g=document.createElement("div");var e=document.createElement("img");g.className="loading";g.align="center";e.src="images/loadingindicator.gif";g.appendChild(e);a.appendChild(g);f.appendChild(a);h.appendChild(f);h.id="listcontent";d.appendChild(h)}function trimString(a){if(typeof(a)=="string"){return a.replace(/^\s+|\s+$/g,"")}else{return a}}function decodeText(a){a=a.replace(/&lt;/g,"<");a=a.replace(/&gt;/g,">");a=a.replace(/&quot;/g,'"');a=a.replace(/&amp;/g,"&");a=a.replace(/&124;/g,"|");a=a.replace(/&35;/g,"#");return a}function decodeListPart(a){a=a.replace(/&38;/g,"&");a=a.replace(/&35;/g,"#");return a}function formatDate(a){var b=a.getDate()+"."+(a.getMonth()+1)+"."+a.getFullYear()+" ";if(a.getHours()<10){b=b+"0"}b=b+a.getHours()+":";if(a.getMinutes()<10){b=b+"0"}b=b+a.getMinutes()+":";if(a.getSeconds()<10){b=b+"0"}b=b+a.getSeconds();return b}function getItemIcon(v,f,d,x,e,n,l,b,a,w,u,h,z){if(f!=null){var o=document.createElement("a");o.href=f}var r=document.createElement("div");if(!v.match(/\//)){r.style.backgroundImage='url("images/wowicons/'+n+"/"+v+'.jpg")'}else{r.style.backgroundImage='url("'+v+'")'}r.style.position="relative";r.style.left="0px";r.style.top="0px";if(n=="medium"){if(l!=true){r.className="itemicon iconpadding"}else{r.className="itemicon"}}if(n=="small"){if(l!=true){r.className="smallitemicon smalliconpadding"}else{r.className="smallitemicon"}}if(n=="tiny"){if(l!=true){r.className="tinyitemicon tinyiconpadding"}else{r.className="tinyitemicon"}}var q=document.createElement("div");q.className="border";var j=document.createElement("div");j.className="noglow";if(d!=null){var g;if(typeof d=="string"){g="this.className='glow'; displayTooltip(event, '"+d.replace(/'/g,"\\'")+"'"}else{g="this.className='glow'; displayTooltip(event, "+recreateArray(d)}if(b!=null){g+=", "+b}else{g+=", null"}if(a!=null){g+=", "+a}else{g+=", null"}if(w!=null){g+=", "+w}else{g+=", null"}if(u!=null){g+=", "+u}else{g+=", null"}if(h!=null){g+=", "+h}else{g+=", null"}g+=");";j.onmouseover=new Function("event",g);j.onmousemove=new Function("event","repositionTooltip(event);");j.onmouseout=new Function("this.className='noglow'; hideTooltip();")}else{j.onmouseover=new Function("event","this.className='glow';");j.onmouseout=new Function("this.className='noglow';")}q.appendChild(j);r.appendChild(q);if((x!=e||x>1)&&n!="tiny"){var t=x;if(x!=e){t=x+"-"+e}var p=document.createElement("div");p.className="count";var m=document.createElement("div");m.appendChild(document.createTextNode(t));m.className="text";p.appendChild(m);var s;for(s=1;s<=8;s++){var y=document.createElement("div");y.className="textborder"+s;y.appendChild(document.createTextNode(t));p.appendChild(y)}j.appendChild(p)}if(z!=null){var c=document.createElement("img");c.src="images/"+z+"_"+n+".png";c.width=36;c.height=13;c.style.position="absolute";c.style.right="4px";c.style.bottom="-2px";r.appendChild(c)}if(f!=null){o.appendChild(r);return o}else{return r}}function addItemIcon(f,e,c,g,a,b,d){var h=f;if(typeof(h)=="string"){h=document.getElementById(f)}if(h!=null){h.appendChild(getItemIcon(e,c,g,a,b,d))}}function addTooltip(d,g,c,b,a,h,f){var e;if(typeof g=="string"){e="displayTooltip(event, '"+g.replace(/'/g,"\\'")+"'"}else{e="displayTooltip(event, "+recreateArray(g)}if(c!=null){e+=", "+c}else{e+=", null"}if(b!=null){e+=", "+b}else{e+=", null"}if(a!=null){e+=", "+a}else{e+=", null"}if(h!=null){e+=", "+h}else{e+=", null"}if(f!=null){e+=", "+f}else{e+=", null"}e+=");";d.onmouseover=new Function("event",e);d.onmousemove=new Function("event","repositionTooltip(event);");d.onmouseout=new Function("hideTooltip();")}function addMoney(d,b){var f=Math.floor(b%100);var a=Math.floor((b/100)%100);var c=Math.floor(b/10000);if(c>0){var e=document.createElement("img");e.src="images/coins/gold.png";e.align="absmiddle";d.appendChild(document.createTextNode(c));d.appendChild(e)}if(a>0||c>0){var e=document.createElement("img");e.src="images/coins/silver.png";e.align="absmiddle";d.appendChild(document.createTextNode(" "+a));d.appendChild(e)}var e=document.createElement("img");e.src="images/coins/copper.png";e.align="absmiddle";d.appendChild(document.createTextNode(" "+f));d.appendChild(e)}function addAltCurrency(e,d,b,g,c){var h;if(b!=null){h=document.createElement("a");h.href=b}var a=document.createElement("img");a.src=d;a.width=16;a.height=16;a.border=0;a.align="absmiddle";if(g!=null){var f;if(typeof g=="string"){f="displayTooltip(event, '"+g.replace(/'/g,"\\'")+"');"}else{f="displayTooltip(event, "+recreateArray(g)+");"}a.onmouseover=new Function("event",f);a.onmousemove=new Function("event","repositionTooltip(event);");a.onmouseout=new Function("hideTooltip();")}e.appendChild(document.createTextNode(c+" "));if(b!=null){h.appendChild(a);e.appendChild(h)}else{e.appendChild(a)}}function addPrice(e,b){if(b.length>0){for(k=0;k<b.length;k++){var g=document.createElement("span");var c=b[k][0];var d=b[k][1];var a=b[k][2];var f=b[k][3];if(c=="money"){addMoney(g,f)}else{if(c=="honor"){addAltCurrency(g,"images/coins/honorpoints.png",null,'<span class="ttwhite">Ehrenpunkte</span>',f)}else{if(c=="arena"){addAltCurrency(g,"images/coins/arenapoints.png",null,'<span class="ttwhite">Arenapunkte</span>',f)}else{addAltCurrency(g,"images/wowicons/small/"+c+".jpg","item?id="+d,a,f)}}}e.appendChild(g)}}}function getElementPosition(b){var a=0;var c=0;if(b.pageX){a=b.pageX;c=b.pageY}else{if(b.offsetLeft){a=absLeft(b);c=absTop(b)}}return{posx:a,posy:c}}function absLeft(a){return(a.offsetParent)?a.offsetLeft+absLeft(a.offsetParent):a.offsetLeft}function absTop(a){return(a.offsetParent)?a.offsetTop+absTop(a.offsetParent):a.offsetTop}function getAntiCacheNumber(){var a=new Date();return a.getTime()}function scrollToBottom(){window.scrollTo(0,getWindowHeight())}function setPermanentCookie(b,c){var a=new Date();a.setTime(a.getTime()+(1000*60*60*24*365));document.cookie=b+"="+escape(c)+"; expires="+a.toGMTString()+";"}function getCookie(b){var c=document.cookie;var d=document.cookie.indexOf("; "+b+"=");if(d==-1){if(document.cookie.indexOf(b+"=")==0){d=0}else{return null}}var f=c.indexOf("=",d)+1;var a=c.indexOf(";",d+1);if(a==-1){a=c.length}var e=c.substring(f,a);return unescape(e)}function deleteCookie(a){document.cookie=a+"=; expires=Thu, 01-Jan-70 00:00:01 GMT;"}function createGenericButton(e,c){var b=document.createElement("a");b.className="genericbutton";b.href=c;var f=document.createElement("div");var d=document.createElement("span");d.appendChild(document.createTextNode(e));f.appendChild(d);b.appendChild(f);return b}function evaluateArray(arraystring){if(arraystring==null){return null}var arr=eval("("+arraystring+")");return arr}function recreateArray(d){var c="[";var a;for(a=0;a<d.length;a++){var b=d[a];if(b==null){c+="null"}else{if(typeof b=="string"){c+="'"+b.replace(/'/g,"\\'")+"'"}else{if(typeof b=="number"){c+=b}else{if(typeof b=="object"){c+=recreateArray(b)}else{c+=b}}}}if(a+1<d.length){c+=","}}c+="]";return c}function addTextBorder(d,c){var h=document.createElement("div");h.style.position="relative";var f=d.firstChild.nodeValue;var a,g;for(a=-c;a<=c;a+=c){for(g=-c;g<=c;g+=c){if(a!=0||g!=0){var b=document.createElement("span");b.className=d.className+" "+d.className+"border";b.style.position="absolute";b.style.left=a+"px";b.style.top=g+"px";b.style.zIndex=1;b.appendChild(document.createTextNode(f));h.appendChild(b)}}}d.style.position="relative";d.style.zIndex=2;var e=d.parentNode;e.removeChild(d);h.appendChild(d);e.appendChild(h)}function displayCategoryPath(h,a){var l=new Array();recursiveCategorySearch(currentcategory,categories,l);l.reverse();var b=document.getElementById(h);b.className="categorypath";removeAllChilds(b);inCategoryList=0;var e;var c=categories;var g=document.createElement("ul");g.className="pathul";for(e=0;e<l.length;e++){var j=document.createElement("li");j.className="pathli";j.id=getStringFromCategoryPath(l,e);var d=document.createElement("a");if(c[l[e]][1]>=categoryajaxfrom&&c[l[e]][1]<=categoryajaxto){d.href="javascript:switchCategory("+c[l[e]][1]+")"}else{d.href=c[l[e]][2]}d.appendChild(document.createTextNode(c[l[e]][0]));setupCategoryDropdown(d,h,j.id,l,e,true,a);j.appendChild(d);j.appendChild(document.createTextNode(" "));if(e<l.length-1){var f=document.createElement("img");f.src="images/arrow2.gif";f.border=0;j.appendChild(f);j.appendChild(document.createTextNode(" "))}c=c[l[e]][3];g.appendChild(j)}b.appendChild(g)}function setupCategoryDropdown(e,c,b,g,h,a,f){if(typeof e=="string"){e=document.getElementById(e)}if(e==null){return}var d="";if(a){d="hideAllCategoryLists();"}else{d='hideCategoryLists(0,"'+c+'");'}e.onmouseover=new Function('enteredCategoryList("'+c+'"); '+d+" displayCategoryList(["+g.join(",")+"],"+h+',"'+b+'",0,0,0,"'+c+'",'+f+");");e.onmouseout=new Function('leftCategoryList("'+c+'");')}function displayCategoryList(r,b,h,z,l,c,n,o){if(typeof h=="string"){h=document.getElementById(h)}if(!h){return}var s;var a=categories;var t=new Array();for(s=0;s<b;s++){a=a[r[s]][3];t.push(r[s])}var j;if(browserIsIE){j=document.documentElement.clientHeight+document.documentElement.scrollTop}else{j=window.innerHeight+window.pageYOffset}var e=true;var g=true;var p=0;var y=0;var m=0;var x=0;if(z>0){x=h.yoffset}var w=null;for(s=0;s<a.length;s++){if(e==true){var v=x;if(s>0){v=u.yoffset}var u=document.createElement("ul");u.style.zIndex=1000;u.className="categorylist";u.yoffset=v;if(z>0||g==false){u.className=u.className+" subcategory";if(w!=null){m+=w.clientWidth+2}u.style.left=(h.clientWidth+m)+"px";u.style.top=(u.yoffset+(l-2)-x)+"px"}u.id="l"+getStringFromCategoryPath(r,b,p);u.depth=z;u.onmouseover=enteredCategoryList;u.onmouseout=new Function('leftCategoryList("'+n+'");');u.yoffset=x;w=u;y=s;p++}g=false;t.push(s);var f=document.createElement("li");f.id="s"+getStringFromCategoryPath(t,(t.length-1));var d=document.createElement("a");if(a[s][1]>=categoryajaxfrom&&a[s][1]<=categoryajaxto){d.href="javascript:switchCategory("+a[s][1]+")"}else{d.href=a[s][2]}var q=24;d.onmouseover=new Function("hideCategoryLists("+(z+1)+',"'+n+'"); displayCategoryList(['+t.join(",")+"],"+(t.length)+',"'+u.id+'",'+(z+1)+","+(q*(s-y)+1)+","+(c+(q*(s-y))+1)+',"'+n+'",'+o+");");d.appendChild(document.createTextNode(a[s][0]));f.appendChild(d);if(a[s][3].length>0){f.className="hassubcategories"}u.appendChild(f);t.pop();if(o+(c+u.yoffset)+(q*(s-y+1))+30>j){if(c+u.yoffset+o-q>15){u.yoffset-=q;u.style.top=(u.yoffset+(l-2)-x)+"px";if(z==0&&u.style.left==0){u.style.left=h.clientWidth+"px"}}else{h.appendChild(u);e=true}}else{e=false}}if(e==false){h.appendChild(u)}operaRedrawPage()}function switchCategory(a,b){currentcategory=a;hideAllCategoryLists();displayCategoryPath("categorypath");resultListStartAt=0;if(/(\/spells)/.test(document.URL)){updateSpellFilterVisibility()}if(b!=true){applyFilter()}}function recursiveCategorySearch(c,d,a){var b;for(b=0;b<d.length;b++){if(d[b][1]==c){a.push(b);return true}else{if(recursiveCategorySearch(c,d[b][3],a)==true){a.push(b);return true}}}return false}function getStringFromCategoryPath(c,e,a){var b;var d="";for(b=0;b<=e;b++){d=d+c[b]+"."}d+="-"+a;return d}var inCategoryList=0;var categoryListActions=0;var categoryContainers=[];function hideCategoryLists(f,b){if(f!=-1||inCategoryList==0){var c=document.getElementById(b);var e=c.getElementsByTagName("ul");var d;var a=new Array();for(d=0;d<e.length;d++){if(e[d].depth>=f){a.push(e[d])}}for(d=0;d<a.length;d++){a[d].parentNode.removeChild(a[d])}}}function autoHideCategoryLists(b,a){if(categoryListActions==b){hideCategoryLists(-1,a)}operaRedrawPage()}function hideAllCategoryLists(){for(i=0;i<categoryContainers.length;i++){hideCategoryLists(0,categoryContainers[i])}operaRedrawPage()}function leftCategoryList(a){inCategoryList--;categoryListActions++;if(inCategoryList==0){window.setTimeout("autoHideCategoryLists("+categoryListActions+',"'+a+'")',500)}}function enteredCategoryList(a){inCategoryList++;categoryListActions++;if(typeof a=="string"){addCategoryContainer(a)}}function addCategoryContainer(a){var b;for(b=0;b<categoryContainers.length;b++){if(categoryContainers[b]==a){return}}categoryContainers[b]=a}function saveListSettingsToURL(){if(skipSavingSettingsToURL==true){skipSavingSettingsToURL=false;return}var f="";f+="f="+encodeURIComponent(filterToUse);var a="";var c;for(c=0;c<columnsToUse.length;c++){if(c>0){a+=":"}a+=columnsToUse[c]}f+="&c="+a;f+="&n="+displayCountPerPage;f+="&b="+resultListStartAt;f+="&s="+resultListSortBy;f+="&d="+resultListSortDirection;f+="&p="+resultListFilterOp;try{var b=convertRatingOptionsToString();f+="&r="+encodeURIComponent(b)}catch(d){}if(filterListVisible==true){f+="&o=1"}window.location.hash=f;expectedHash=window.location.hash;if(browserIsIE){window.frames.iehistoryframe.window.location.search="?"+f}}function restoreListSettingsFromURL(){var g=window.location.hash;if(g==null){return}if(g.slice(0,1)=="#"){g=g.slice(1)}var c=g.split("&");var d,a;for(d=0;d<c.length;d++){if(c[d].length>1){var f=c[d].slice(0,1);var b=decodeURIComponent(c[d].slice(2));if(f=="f"){filterToUse=b;updateFilterDisplay()}if(f=="o"){if(b=="1"){showFilters()}}if(f=="c"){columnsToUse=new Array();var j=b.split(":");for(a=0;a<j.length;a++){columnsToUse.push(Number(j[a]))}}if(f=="n"){displayCountPerPage=Number(b)}if(f=="b"){resultListStartAt=Number(b)}if(f=="s"){resultListSortBy=Number(b)}if(f=="d"){resultListSortDirection=Number(b)}if(f=="r"){try{convertStringToRatingOptions(decodeURIComponent(b))}catch(h){}}if(f=="p"){if(b=="or"){resultListFilterOp="or"}else{resultListFilterOp="and"}updateFilterOperatorDisplay()}}}}function saveTabSettingsToURL(){if(skipSavingSettingsToURL==true){skipSavingSettingsToURL=false;return}var a="";a+="t="+selectedTab;if(tabSortBy!=-1){a+="&l="+tabSortBy}if(tabSortDirection!=-1){a+="&x="+tabSortDirection}if(tabStartAt!=-1){a+="&a="+tabStartAt}window.location.hash=a;expectedHash=window.location.hash;if(browserIsIE){window.frames.iehistoryframe.window.location.search="?"+a}}function restoreTabSettingsFromURL(){var f=window.location.hash;if(f==null){return}if(f.slice(0,1)=="#"){f=f.slice(1)}var c=f.split("&");var d,a;var g=false;selectedTab=0;tabSortBy=-1;tabSortDirection=-1;tabStartAt=0;for(d=0;d<c.length;d++){if(c[d].length>2){var e=c[d].slice(0,1);var b=decodeURIComponent(c[d].slice(2));if(e=="t"){selectedTab=Number(b);g=true}if(e=="l"){tabSortBy=Number(b)}if(e=="x"){tabSortDirection=Number(b)}if(e=="a"){tabStartAt=Number(b)}}}displayTab(selectedTab,tabSortBy,tabSortDirection,tabStartAt)}var expectedHash=null;var skipSavingSettingsToURL=false;function handleHistory(){var a=window.location.hash;if(expectedHash!=null&&a!=expectedHash){expectedHash=a;skipSavingSettingsToURL=true;if(top.historyType=="list"){restoreListSettingsFromURL();applyFilter()}if(top.historyType=="tabs"){restoreTabSettingsFromURL()}}}function operaHandleHistory(){if(browserIsOpera){handleHistory()}}function setupHistoryHandling(){if(browserIsOpera){window.setInterval("handleHistory()",500)}}var contentsize_old=0;var contentheight_old=0;var fullsize_old=0;var skipUpdatingBackground=false;function checkWindowSize(c){var d=getWindowWidth();var a=d-50;var b=a;if(a>1220){a=1220}if(a<960){a=960}if(a!=contentsize_old){if(setContentSize(a)==true){contentsize_old=a}}var e=getPageHeight();if((c==true||!skipUpdatingBackground)&&(e!=contentheight_old||b!=fullsize_old)){contentheight_old=e;fullsize_old=b;updateBackground(e,b)}}function setContentSize(b){try{var f=document.getElementById("innercontainertable");f.style.width=b+"px";f.width=b;var c=document.getElementById("headerbg_outer");var a=document.getElementById("headerbg_overflow");a.style.width=(b-175)+"px";c.style.backgroundImage="";return true}catch(d){return false}}function setupWindowSizeChecks(){checkWindowSize(true);window.setInterval("checkWindowSize()",500)}function windowAtFullSize(){var b=getWindowWidth();var a=b-40;if(a>=1220){return true}else{return false}}function windowAtHalfSize(){var b=getWindowWidth();var a=b-40;if(a>=1040){return true}else{return false}}function getPageHeight(){var a=document.getElementById("innercontainertable");return a.clientHeight+60}var backgroundcontainer=null;function updateBackground(h,a){var m=(a<1280);var g=document.createElement("div");g.id="backgroundContainer";var j=document.createElement("div");j.id="backgroundImageTop";j.className=(m?"smallBackgroundImageTop":"");g.appendChild(j);var l;if(h>1020){if((h-1020-94)<0){h+=Math.abs((h-1020-94)%90)}else{h+=90-((h-1020-94)%90)}l=true}else{h+=90-((h-34)%90);l=false}var b=document.createElement("div");b.id="backgroundImageBottom";b.className=(m?"smallBackgroundImageBottom":"");g.appendChild(b);var f=document.createElement("div");f.id="backgroundImageIntermediate";f.className=(m?"smallBackgroundImageIntermediate":"");g.appendChild(f);if(l){var d;for(d=1020;d<h;d+=1800){var c=h-d;if(c>1800){c=1800}var e=document.createElement("div");e.className=(m?"smallBackgroundImageMiddle":"backgroundImageMiddle");e.style.height=c+"px";e.style.top=d+"px";g.appendChild(e)}j.style.height="1020px"}else{j.style.height=h+"px"}b.style.top=(h-184)+"px";f.style.top=(h-(184+90))+"px";if(backgroundcontainer!=null){document.body.replaceChild(g,backgroundcontainer)}else{document.body.appendChild(g)}backgroundcontainer=g}var SDLS_livesearchbox=null;var SDLS_livesearchhiddentype=null;var SDLS_livesearchwidth=200;var SDLS_livesearchattachment="right";var SDLS_livesearchoffset=0;var SDLS_livesearchnumentries=0;var SDLS_livesearchkeystate=0;var SDLS_livesearchintervalhandler=null;var SDLS_livesearchentries=[];var SDLS_livesearchdelayedquery="";var SDLS_livesearchdelayhandler=null;var SDLS_hostprefix="http://www.mobmap.de/";var browserIsIE=(navigator.appName=="Microsoft Internet Explorer");var browserIsOpera=(navigator.userAgent.search(/Opera/)!=-1);var browserIsSafari=(navigator.userAgent.search(/Safari/)!=-1);var browserIsNetscape=(!browserIsSafari&&navigator.appName=="Netscape");function SDLS_attachLiveSearch(b,c,e,d){var a=document.getElementById(b);if(a){SDLS_livesearchbox=a;SDLS_livesearchwidth=c;SDLS_livesearchattachment=e;SDLS_livesearchoffset=d;SDLS_livesearchbox.onkeyup=SDLS_performLiveSearch;SDLS_livesearchbox.onkeydown=SDLS_liveSearchKeyDown;SDLS_livesearchbox.onblur=new Function('window.setTimeout("SDLS_hideLiveSearchResults()", 200)');SDLS_livesearchbox.autocomplete="off";if(browserIsNetscape){SDLS_livesearchbox.setAttribute("autocomplete","off")}SDLS_livesearchhiddentype=document.createElement("input");SDLS_livesearchhiddentype.type="hidden";SDLS_livesearchhiddentype.name="querytype";SDLS_livesearchhiddentype.id="querytype";SDLS_livesearchhiddentype.value="";a.parentNode.appendChild(SDLS_livesearchhiddentype)}}function SDLS_initialize(){if(document.getElementById("tooltip0")==null){var g=document.getElementsByTagName("head")[0];if(g){var d=document.createElement("link");d.type="text/css";d.href=SDLS_hostprefix+"css/extlivesearch.css";d.rel="stylesheet";g.appendChild(d);d=document.createElement("script");d.src=SDLS_hostprefix+"js/tooltip.js";g.appendChild(d)}var c=document.getElementsByTagName("body")[0];if(c){for(var e=0;e<3;e++){var f=document.createElement("div");f.id="tooltip"+e;f.className="sdtooltip sdtooltipwide";f.style.position="absolute";f.style.zIndex=1000000000;f.style.left="0px";f.style.top="0px";f.style.visibility="hidden";var j=document.createElement("table");j.border=0;j.cellPadding=0;j.cellSpacing=0;j.style.tableLayout="auto";var a=document.createElement("tr");var m=document.createElement("td");m.id="tooltipcontainer"+e;a.appendChild(m);m=document.createElement("td");m.className="tooltip-padded";m.style.backgroundPosition="100% 0%";a.appendChild(m);j.appendChild(a);a=document.createElement("tr");m=document.createElement("td");m.className="tooltip-padded";m.style.backgroundPosition="0% 100%";m.appendChild(document.createTextNode(" "));a.appendChild(m);m=document.createElement("td");m.className="tooltip-padded";m.style.backgroundPosition="100% 100%";m.appendChild(document.createTextNode(" "));a.appendChild(m);j.appendChild(a);f.appendChild(j);c.appendChild(f)}}}}function SDLS_performLiveSearch(b){if(!b){b=window.event}if(b.keyCode==38||b.keyCode==40){SDLS_livesearchkeystate=0;SDLS_clearLiveSearchIntervalHandler();return}if(b.keyCode!=13){var a=SDLS_livesearchbox.value;if(a.length>=3&&b.keyCode!=27){SDLS_livesearchdelayedquery=a;if(SDLS_livesearchdelayhandler!=null){window.clearTimeout(SDLS_livesearchdelayhandler);SDLS_livesearchdelayhandler=null}SDLS_livesearchdelayhandler=window.setTimeout("SDLS_actuallyPerformLiveSearch()",150)}else{SDLS_hideLiveSearchResults()}}}function SDLS_actuallyPerformLiveSearch(){var b=SDLS_livesearchbox.value;if(b.length>=3&&b==SDLS_livesearchdelayedquery){var a=SDLS_hostprefix+"search?mode=livesearch&query="+encodeURIComponent(b);SDLS_startAJAXRequest(a)}}function SDLS_startAJAXRequest(a){var b=document.getElementById("SDLSRequest");var c=document.getElementsByTagName("head")[0];if(b){c.removeChild(b)}b=document.createElement("script");b.id="SDLSRequest";b.type="text/javascript";b.src=a;c.appendChild(b)}function SDLS_liveSearchKeyDown(a){if(!a){a=window.event}if(a.keyCode==38||a.keyCode==40){if(SDLS_livesearchnumentries>0){SDLS_livesearchkeystate=a.keyCode;if(browserIsOpera||browserIsNetscape){SDLS_livesearchintervalhandler=window.setInterval("SDLS_performLiveSearchInterval(true)",500)}SDLS_processLiveSearchKeyboardMovement((a.keyCode==40))}}}function SDLS_clearLiveSearchIntervalHandler(){if(SDLS_livesearchintervalhandler!=null){window.clearInterval(SDLS_livesearchintervalhandler);SDLS_livesearchintervalhandler=null}}function SDLS_performLiveSearchInterval(a){if(SDLS_livesearchkeystate==0){SDLS_clearLiveSearchIntervalHandler();return}if(a==true){SDLS_clearLiveSearchIntervalHandler();SDLS_livesearchintervalhandler=window.setInterval("SDLS_performLiveSearchInterval(false)",30)}SDLS_processLiveSearchKeyboardMovement((SDLS_livesearchkeystate==40))}function SDLS_displayResults(u){var j=document.getElementById("livesearchcontainer");var g=document.getElementById("livesearchtable");if(j==null){j=document.createElement("div");j.id="livesearchcontainer";SDLS_livesearchbox.parentNode.appendChild(j);g=SDLS_getTable(SDLS_livesearchwidth,0,1,0);g.id="livesearchtable";j.appendChild(g)}j.width=SDLS_livesearchwidth+"px";if(SDLS_livesearchattachment=="left"){j.style.left=SDLS_livesearchoffset+"px"}else{j.style.right=SDLS_livesearchoffset+"px"}g.width=SDLS_livesearchwidth;var l=u;if(l.length>1){if(l[0]==SDLS_livesearchbox.value){SDLS_removeAllChilds(g);var m=document.createElement("tbody");var r=0;SDLS_livesearchentries=[];for(r=1;r<l.length;r++){var w=l[r][0];var b=l[r][1];var p=l[r][2];var t=l[r][3];var d=l[r][4];var e="search?query="+encodeURIComponent(w+" ("+b+")");var c=document.createElement("tr");c.className="livesearchresult clickable";c.id="livesearchresult"+(r-1);var h=document.createElement("td");var n=SDLS_getTable("100%",0,0,1);n.style.height="24px";var s=document.createElement("tbody");var o=document.createElement("tr");var v=document.createElement("td");v.width=22;if(t!=""){v.appendChild(SDLS_getItemIcon(t,e,d,0,0,"tiny",true))}o.appendChild(v);v=document.createElement("td");v.vAlign="middle";v.align="left";var f=document.createElement("div");f.className="q"+((p!="1")?p:"1b");var q=document.createElement("span");q.appendChild(document.createTextNode(w));if(t!=""){SDLS_addTooltip(q,d)}f.appendChild(q);v.appendChild(f);o.appendChild(v);v=document.createElement("td");v.vAlign="middle";v.align="right";v.className="livesearchtypetag";v.appendChild(document.createTextNode(b));o.appendChild(v);s.appendChild(o);n.appendChild(s);h.appendChild(n);c.appendChild(h);c.onclick=new Function("document.location.href='"+SDLS_hostprefix+e.replace("'","\\'")+"';");m.appendChild(c);SDLS_livesearchentries[r-1]=[w,b]}SDLS_livesearchnumentries=l.length-1;g.appendChild(m);j.appendChild(g);j.style.visibility="visible";var a=document.getElementById("tobehiddenbylivesearch");if(a){a.style.visibility="hidden"}}else{SDLS_hideLiveSearchResults()}}else{SDLS_hideLiveSearchResults()}}function SDLS_hideLiveSearchResults(){var a=document.getElementById("livesearchcontainer");if(a){a.style.visibility="hidden"}SDLS_livesearchnumentries=0;if(SDLS_livesearchhiddentype){SDLS_livesearchhiddentype.value=""}var b=document.getElementById("tobehiddenbylivesearch");if(b){b.style.visibility="visible"}}function SDLS_processLiveSearchKeyboardMovement(c){var a;if(c==true){var b=SDLS_getCurrentlySelectedLiveSearchEntry();a=b+1;if(a>=SDLS_livesearchnumentries){a=0}SDLS_selectLiveSearchEntry(a)}else{var b=SDLS_getCurrentlySelectedLiveSearchEntry();a=b-1;if(a<0){a=SDLS_livesearchnumentries-1}SDLS_selectLiveSearchEntry(a)}SDLS_livesearchbox.value=SDLS_livesearchentries[a][0];SDLS_livesearchhiddentype.value=SDLS_livesearchentries[a][1]}function SDLS_deselectLiveSearchEntries(){var a;for(a=0;a<SDLS_livesearchnumentries;a++){var b=document.getElementById("livesearchresult"+a);if(b){b.className="livesearchresult"}}}function SDLS_selectLiveSearchEntry(b){SDLS_deselectLiveSearchEntries();if(b==-1){SDLS_livesearchbox.focus()}else{var a=document.getElementById("livesearchresult"+b);if(a){a.className="livesearchresult livesearchselected"}}}function SDLS_getCurrentlySelectedLiveSearchEntry(){var a;for(a=0;a<SDLS_livesearchnumentries;a++){var b=document.getElementById("livesearchresult"+a);if(b){if(b.className.search(/livesearchselected/)!=-1){return a}}}return -1}function SDLS_processLiveSearchMouseOver(a){SDLS_selectLiveSearchEntry(a)}function SDLS_removeAllChilds(a){while(a.firstChild){a.removeChild(a.firstChild)}}function SDLS_getTable(b,a,e,d){var c=document.createElement("table");c.width=b;c.border=a;c.cellSpacing=e;c.cellPadding=d;return c}function SDLS_getItemIcon(v,f,d,x,e,n,l,b,a,w,u,h,z){if(f!=null){var o=document.createElement("a");o.href=f}var r=document.createElement("div");if(!v.match(/\//)){r.style.backgroundImage='url("'+SDLS_hostprefix+"images/wowicons/"+n+"/"+v+'.jpg")'}else{r.style.backgroundImage='url("'+v+'")'}r.style.position="relative";r.style.left="0px";r.style.top="0px";if(n=="medium"){if(l!=true){r.className="itemicon iconpadding"}else{r.className="itemicon"}}if(n=="small"){if(l!=true){r.className="smallitemicon smalliconpadding"}else{r.className="smallitemicon"}}if(n=="tiny"){if(l!=true){r.className="tinyitemicon tinyiconpadding"}else{r.className="tinyitemicon"}}var q=document.createElement("div");q.className="border";var j=document.createElement("div");j.className="noglow";if(d!=null){var g;if(typeof d=="string"){g="this.className='glow'; displayTooltip(event, '"+d.replace(/'/g,"\\'")+"'"}else{g="this.className='glow'; displayTooltip(event, "+recreateArray(d)}if(b!=null){g+=", "+b}else{g+=", null"}if(a!=null){g+=", "+a}else{g+=", null"}if(w!=null){g+=", "+w}else{g+=", null"}if(u!=null){g+=", "+u}else{g+=", null"}if(h!=null){g+=", "+h}else{g+=", null"}g+=");";j.onmouseover=new Function("event",g);j.onmousemove=new Function("event","repositionTooltip(event);");j.onmouseout=new Function("this.className='noglow'; hideTooltip();")}else{j.onmouseover=new Function("event","this.className='glow';");j.onmouseout=new Function("this.className='noglow';")}q.appendChild(j);r.appendChild(q);if((x!=e||x>1)&&n!="tiny"){var t=x;if(x!=e){t=x+"-"+e}var p=document.createElement("div");p.className="count";var m=document.createElement("div");m.appendChild(document.createTextNode(t));m.className="text";p.appendChild(m);var s;for(s=1;s<=8;s++){var y=document.createElement("div");y.className="textborder"+s;y.appendChild(document.createTextNode(t));p.appendChild(y)}j.appendChild(p)}if(z!=null){var c=document.createElement("img");c.src="images/"+z+"_"+n+".png";c.width=36;c.height=13;c.style.position="absolute";c.style.right="4px";c.style.bottom="-2px";r.appendChild(c)}if(f!=null){o.appendChild(r);return o}else{return r}}function SDLS_addTooltip(d,g,c,b,a,h,f){var e;if(typeof g=="string"){e="displayTooltip(event, '"+g.replace(/'/g,"\\'")+"'"}else{e="displayTooltip(event, "+recreateArray(g)}if(c!=null){e+=", "+c}else{e+=", null"}if(b!=null){e+=", "+b}else{e+=", null"}if(a!=null){e+=", "+a}else{e+=", null"}if(h!=null){e+=", "+h}else{e+=", null"}if(f!=null){e+=", "+f}else{e+=", null"}e+=");";d.onmouseover=new Function("event",e);d.onmousemove=new Function("event","repositionTooltip(event);");d.onmouseout=new Function("hideTooltip();")}var pinneditemslots=[["Kopf"],["Hals"],["Schultern"],["Hemd"],["Brust"],["Handgelenke"],["Hände"],["Gürtel"],["Beine"],["Füße"],["Rücken"],["Waffe links","Waffe rechts"],["Distanz/Relikt"],["Munition"],["Ring 1","Ring 2"],["Schmuck 1","Schmuck 2"]];var pinneditemtype=null;var pinneditemdata=null;var pinneditemsaveddata=null;function setupPinnedItems(n,d){if(d!=null){pinneditemtype=d}if(n!=null){pinneditemdata=n}var a=document.createElement("div");a.id="smallpinneditemcontainer";var e=document.createElement("img");e.src="images/pinicon.png";e.align="absmiddle";a.appendChild(e);var m=null;var g=getPinnedItemCount(pinneditemdata);if(g==1){m="1 Gegenstand"}else{m=g+" Gegenstände"}var j=document.createElement("a");j.href="javascript:togglePinnedItems()";j.appendChild(document.createTextNode(m));a.appendChild(j);var b=document.getElementById("pinneditems");removeAllChilds(b);if(typeof identifiertype!="undefined"&&identifiertype==1&&pinneditemtype!=null){if(isItemCurrentlyPinned(pinneditemdata,identifier)==true){b.appendChild(createGenericButton("lösen","javascript:unpinItem("+identifier+");"))}else{if(pinneditemslots[pinneditemtype].length>1){var h=0;var c=0;for(h=0;h<pinneditemslots[pinneditemtype].length;h++){if(c==0&&pinneditemdata[pinneditemtype][h]!=null){c=h+1}}if(c>pinneditemslots[pinneditemtype].length){c=0}var l=document.createElement("select");l.id="pinneditemsubslot";for(h=0;h<pinneditemslots[pinneditemtype].length;h++){var f=document.createElement("option");f.value=h;f.appendChild(document.createTextNode(pinneditemslots[pinneditemtype][h]));if(c==h){f.selected=true;f.defaultSelected=true}l.appendChild(f)}l.selectedIndex=c;l.value=c;b.appendChild(l)}b.appendChild(createGenericButton("festpinnen","javascript:pinItem("+identifier+");"))}}b.appendChild(a)}function togglePinnedItems(){reallyTogglePinnedItems();loadPinnedItemSetList()}function reallyTogglePinnedItems(){var b=document.getElementById("pinneditemcontainer");if(b==null){b=document.createElement("div");b.id="pinneditemcontainer";var c=document.getElementById("pinneditems");c.appendChild(b)}else{removeFromParent(b);return}var t=document.createElement("table");var j=document.createElement("tbody");t.cellSpacing=2;var h,e;for(h=0;h<pinneditemslots.length;h++){for(e=0;e<pinneditemslots[h].length;e++){var r=pinneditemslots[h][e];var g=pinneditemdata[h][e];var o=document.createElement("tr");var d=document.createElement("td");d.width=110;d.className="pinneditemtitle";d.appendChild(document.createTextNode(r+":"));o.appendChild(d);d=document.createElement("td");d.width=22;if(g==null){var f=document.createElement("img");f.src="images/emptysockettiny.gif";d.appendChild(f)}else{d.appendChild(getItemIcon(g[2],"item?id="+g[0],g[4],0,0,"tiny",false,0,0,0,0,null))}o.appendChild(d);d=document.createElement("td");d.width=240;d.align="left";d.valign="middle";if(g!=null){var q=document.createElement("a");q.className="pinneditemname q"+g[1]+((g[1]==1)?"b":"");q.href="item?id="+g[0];addTooltip(q,g[4],0,0,0,0,null);q.appendChild(document.createTextNode(g[3]));d.appendChild(q)}else{d.appendChild(document.createTextNode("-"))}o.appendChild(d);d=document.createElement("td");d.width=22;if(g!=null){var q=document.createElement("a");q.href="javascript:unpinItem("+g[0]+");";var f=document.createElement("img");f.src="images/deletepinneditembutton.png";f.border=0;q.appendChild(f);d.appendChild(q)}o.appendChild(d);j.appendChild(o)}}t.appendChild(j);b.appendChild(t);t=document.createElement("table");t.cellSpacing=0;t.cellPadding=0;t.width="100%";j=document.createElement("tbody");o=document.createElement("tr");d=document.createElement("td");d.width="33%";d.align="left";var q=document.createElement("a");q.href="javascript:toggleArmoryPIInput()";q.appendChild(document.createTextNode("-> Arsenal-Import"));q.className="pinneditemsreadfromarmorylink";d.appendChild(q);o.appendChild(d);d=document.createElement("td");d.width="33%";d.align="center";q=document.createElement("a");q.href="javascript:togglePIStorageInput()";q.appendChild(document.createTextNode("-> Speicherfunktionen"));q.className="pinneditemsreadfromarmorylink";d.appendChild(q);o.appendChild(d);d=document.createElement("td");d.width="34%";d.align="right";q=document.createElement("a");q.href="javascript:wipePinnedItems()";q.appendChild(document.createTextNode("-> neues Set erstellen"));q.className="pinneditemsreadfromarmorylink";d.appendChild(q);o.appendChild(d);j.appendChild(o);t.appendChild(j);b.appendChild(t);var n=document.createElement("div");n.id="pinneditemarmorysection";n.appendChild(document.createTextNode("Arsenal-URL: "));var p=document.createElement("input");p.id="pinneditemarmoryurl";p.size=30;n.appendChild(p);n.appendChild(document.createTextNode(" "));var m=document.createElement("button");m.appendChild(document.createTextNode("einlesen"));m.onclick=new Function("readPinnedItemsFromArmory();");n.appendChild(m);b.appendChild(n);n=document.createElement("div");n.id="pinneditemstoragesection";if(pinneditemsaveddata!=null){if(pinneditemdata[pinneditemdata.length-2]>0){n.appendChild(document.createTextNode("Derzeit geladenes Set: "));var s=document.createElement("strong");s.appendChild(document.createTextNode(pinneditemdata[pinneditemdata.length-1]));s.style.lineHeight="26px";n.appendChild(s);n.appendChild(document.createElement("br"))}n.appendChild(document.createTextNode("Optionen: "));m=document.createElement("button");m.appendChild(document.createTextNode("Set speichern"));m.onclick=new Function("savePinnedItems();");n.appendChild(m);if(pinneditemsaveddata.length>0){n.appendChild(document.createTextNode(" | "));p=document.createElement("select");p.id="pinneditemsetlist";var h;for(h=0;h<pinneditemsaveddata.length;h++){var l=document.createElement("option");l.value=pinneditemsaveddata[h][0];l.text=pinneditemsaveddata[h][1];p.appendChild(l)}n.appendChild(p);n.appendChild(document.createTextNode(" "));var m=document.createElement("button");m.appendChild(document.createTextNode("laden"));m.onclick=new Function("loadPinnedItems();");n.appendChild(m);n.appendChild(document.createTextNode(" "));var m=document.createElement("button");m.appendChild(document.createTextNode("löschen"));m.onclick=new Function("deletePinnedItemSet();");n.appendChild(m)}}else{n.appendChild(document.createTextNode("Um Sets abspeichern und laden zu können, musst du eingeloggt sein!"))}b.appendChild(n);if(pinneditemsaveddata!=null){togglePIStorageInput()}}function toggleArmoryPIInput(){hidePIStorageInput();document.getElementById("pinneditemarmorysection").style.display=(document.getElementById("pinneditemarmorysection").style.display=="block"?"none":"block")}function hideArmoryPIInput(){document.getElementById("pinneditemarmorysection").style.display="none"}function togglePIStorageInput(){hideArmoryPIInput();document.getElementById("pinneditemstoragesection").style.display=(document.getElementById("pinneditemstoragesection").style.display=="block"?"none":"block")}function hidePIStorageInput(){document.getElementById("pinneditemstoragesection").style.display="none"}function getPinnedItemCount(d){var b,a,c=0;for(b=0;b<d.length-2;b++){for(a=0;a<d[b].length;a++){if(d[b][a]!=null){c++}}}return c}function pinItem(d){var a=0;var c=document.getElementById("pinneditemsubslot");if(c){a=c.value}var b="gensrv?action=setpinneditem&slot="+pinneditemtype+"&subslot="+a+"&id="+d;startAJAXRequest(b,updatePinnedItems)}function unpinItem(b){var a="gensrv?action=unsetpinneditem&id="+b;startAJAXRequest(a,updatePinnedItems)}function updatePinnedItems(b){var a=false;if(document.getElementById("pinneditemcontainer")!=null){a=true}setupPinnedItems(evaluateArray(b));if(a){reallyTogglePinnedItems()}}function readPinnedItemsFromArmory(){var a=document.getElementById("pinneditemarmoryurl").value;var b="gensrv?action=setpinnedfromarmory&url="+encodeURIComponent(a);startAJAXRequest(b,finishReadPinnedItemsFromArmory)}function finishReadPinnedItemsFromArmory(a){if(a.charAt(0)=="["){updatePinnedItems(a)}else{alert(a)}}function loadPinnedItemSetList(){var a="gensrv?action=getpinnedlist";startAJAXRequest(a,finishLoadPinnedItemSetList)}function finishLoadPinnedItemSetList(a){if(a.charAt(0)=="["){pinneditemsaveddata=evaluateArray(a)}else{pinneditemsaveddata=null}updatePinnedItems()}function savePinnedItems(){var b="";if(pinneditemdata[pinneditemdata.length-2]>0){b=pinneditemdata[pinneditemdata.length-1]}var a=prompt("Gewünschter Name des Sets",b);if(a){var c="gensrv?action=savepinned&name="+encodeURIComponent(a);startAJAXRequest(c,finishSavePinnedItems)}}function finishSavePinnedItems(a){if(a.charAt(0)=="["){updatePinnedItems(a);loadPinnedItemSetList()}else{alert(a)}}function loadPinnedItems(){var b=document.getElementById("pinneditemsetlist").value;if(b&&b>0){var a="gensrv?action=loadpinned&id="+b;startAJAXRequest(a,finishLoadPinnedItems)}}function finishLoadPinnedItems(a){if(a.charAt(0)=="["){updatePinnedItems(a)}else{alert(a)}}function deletePinnedItemSet(){var b=document.getElementById("pinneditemsetlist").value;if(b&&b>0){var a="gensrv?action=deletepinned&id="+b;startAJAXRequest(a,finishDeletePinnedItemSet)}}function finishDeletePinnedItemSet(a){if(a.charAt(0)=="["){var b=document.getElementById("pinneditemsetlist").value;if(b==pinneditemdata[pinneditemdata.length-2]){pinneditemdata[pinneditemdata.length-2]=0}pinneditemsaveddata=evaluateArray(a);updatePinnedItems()}else{alert(a)}}function wipePinnedItems(){var a="gensrv?action=wipepinned";startAJAXRequest(a,finishWipePinnedItems)}function finishWipePinnedItems(a){updatePinnedItems(a)}function isItemCurrentlyPinned(a,b){for(i=0;i<a.length;i++){for(k=0;k<a[i].length;k++){if(a[i][k]!=null&&a[i][k][0]==b){return true}}}return false}function setupLoggedInAs(){var d=document.getElementById("headerlogin");if(loggedinas!=null){var c=document.createElement("strong");c.appendChild(document.createTextNode(loggedinas));d.appendChild(c);d.appendChild(document.createTextNode(" | "));var b=document.createElement("a");b.href="login";b.appendChild(document.createTextNode("ausloggen"));d.appendChild(b)}else{var b=document.createElement("a");b.href="login";b.appendChild(document.createTextNode("einloggen"));d.appendChild(b);d.appendChild(document.createTextNode(" | "));var b=document.createElement("a");b.href="signup";b.appendChild(document.createTextNode("registrieren"));d.appendChild(b)}}function setupNewFeatureAd(a){var b=document.getElementById("newfeaturead");if(getCookie("newfeaturead")!=a){b.style.display=""}else{b.style.display="none"}}function followNewFeatureAd(b,a){setPermanentCookie("newfeaturead",a);window.open(b)}function hideNewFeatureAd(a){setPermanentCookie("newfeaturead",a);setupNewFeatureAd(a)}var selectedTab=0;var tabSortBy=-1;var tabSortDirection=-1;var tabStartAt=0;var historyType="tabs";var preventTabSaving=true;function renderTabs(){var f;var j=document.getElementById("tablist");for(f=0;f<tabdata.length;f++){var g=0;var h=tabdata[f][0];if(h>=100&&h<110){g=tabdata[f][2]}else{if(h<100){g=tabdata[f][2].length}}var a;if(g>0){a=tabdata[f][1]+" ("+g+")"}else{a=tabdata[f][1]}var m=document.createElement("li");var e=document.createElement("div");e.className="tab_l";var d=document.createElement("div");d.className="tab_m";var c=document.createElement("div");c.className="tab_r";var l=document.createElement("a");var b=document.createElement("strong");l.href="javascript:displayTab("+f+",-1,-1,0);";l.appendChild(document.createTextNode(a));b.appendChild(document.createTextNode(a));d.appendChild(l);d.appendChild(b);m.appendChild(e);m.appendChild(d);m.appendChild(c);j.appendChild(m)}}function displayTab(d,c,B,P){setActiveTab(d);var T,S;var aT=document.getElementById("listbody");var ae=document.getElementById("listcontent");var F=tabdata[d][0];var aW=tabdata[d][2];var x=0;if(F<100){x=aW.length}else{if(F<110){x=aW}}var aF=x-P;if(aF>50){aF=50}if(ae!=null){aT.removeChild(ae)}if(F==23||F==60){if(c==-1){c=1}if(B==-1){B=0}}if(F==1){if(c==-1){c=1}if(B==-1){B=0}}if(F==2||F==3||F==11||F==20){if(c==-1){c=1}if(B==-1){B=0}}if(F==4||F==8||F==21||F==24){if(c==-1){c=6}if(B==-1){B=0}}if(F==9||F==13||F==7||F==91||F==94||F==93){if(c==-1){c=5}if(B==-1){B=1}}if(F==5||F==10||F==12||F==22||F==35||F==36||F==51||F==52||F==62){if(c==-1){c=1}if(B==-1){B=0}}if(F==6||F==14||F==15||F==16){if(c==-1){c=7}if(B==-1){B=1}}if(F==30||F==31||F==32||F==33||F==34){if(c==-1){c=8}if(B==-1){B=1}}if(F==17||F==18||F==19){if(c==-1){c=4}if(B==-1){B=1}}if(F==38||F==90){if(c==-1){c=1}if(B==-1){B=0}}if(F==50||F==53||F==54){if(c==-1){c=9}if(B==-1){B=1}}if(F==37){if(c==-1){c=1}if(B==-1){B=0}}if(F==63){if(c==-1){c=9}if(B==-1){B=1}}if(F==70){if(c==-1){c=8}if(B==-1){B=0}}if(F==71){if(c==-1){c=9}if(B==-1){B=1}}if(F==80){if(c==-1){c=10}if(B==-1){B=1}}if(F==81){if(c==-1){c=9}if(B==-1){B=1}}if(F==82){if(c==-1){c=13}if(B==-1){B=1}}if(F==83){if(c==-1){c=9}if(B==-1){B=1}}if(F==84){if(c==-1){c=8}if(B==-1){B=1}}if(F==85){if(c==-1){c=5}if(B==-1){B=1}}if(F==86){if(c==-1){c=7}if(B==-1){B=1}}if(F==87){if(c==-1){c=3}if(B==-1){B=1}}if(F==88){if(c==-1){c=10}if(B==-1){B=1}}if(F==92){if(c==-1){c=7}if(B==-1){B=1}}if(F==64||F==65||F==66||F==67||F==68||F==69){if(c==-1){c=5}if(B==-1){B=1}}if(F==95){if(c==-1){c=1}if(B==-1){B=1}}var aP=(B+1)%2;if(F==23||F==60||F==84){if(c==1){sortListLex(aW,1,B)}if(c==4){sortListNum(aW,4,B)}if(c==6){sortListLex(aW,6,B)}if(c==7){sortListLex(aW,7,B)}if(c==9){sortListNum(aW,9,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,(F!=84)?"35%":"30%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",4,"+((c==4)?aP:0)+","+P+");","Stufe",(c==4)?B:-1));C.appendChild(getListContentHeader(false,"40%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Aufenthaltsort",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Kategorie",(c==7)?B:-1));if(F==84){C.appendChild(getListContentHeader(false,"5%","javascript:displayTab("+d+",9,"+((c==9)?aP:0)+","+P+");","Score",(c==9)?B:-1))}K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='npc?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.className="bold";aB.href="npc?id="+aV[0];aB.appendChild(document.createTextNode(aV[1]));var ad=getListTableElement("left",aB);if(aV[3]!=null){addTooltip(ad,aV[3])}if(aV[2]!=null){var ar=document.createElement("span");ar.className="smalltext block";ar.appendChild(document.createTextNode(aV[2]));ad.appendChild(ar)}var aA=getListTableElement("center",document.createTextNode(formatMobLevelString(aV[4],aV[5])));var Q=getListTableElement("center",null);for(S=0;S<aV[6].length;S++){if(S>0&&aV[6][S].length==2){Q.appendChild(document.createTextNode(", "))}if(aV[6][S].length==2){var al=document.createElement("a");al.href="zone?id="+aV[6][S][0];al.appendChild(document.createTextNode(aV[6][S][1]));Q.appendChild(al)}else{Q.appendChild(document.createTextNode(" ("+aV[6][S][0]+" weitere)"))}}var af=getListTableElement("center",null);getLinkElement(aV[7],"npcs?category="+aV[8],af);var X=null;if(aV[9]!=null){X=getListTableElement("center",document.createTextNode(formatScore(aV[9])))}appendMultipleChilds(C,[ad,aA,Q,af,X]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==1){if(c==1){sortListLex(aW,1,B)}if(c==4){sortListNum(aW,4,B)}if(c==6){sortListLex(aW,6,B)}if(c==8){sortListNum(aW,8,B)}if(c==9){sortListMoney(aW,9,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"25%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",4,"+((c==4)?aP:0)+","+P+");","Stufe",(c==4)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Aufenthaltsort",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Vorrat",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Menge",(c==8)?B:-1));C.appendChild(getListContentHeader(false,"25%","javascript:displayTab("+d+",9,"+((c==9)?aP:0)+","+P+");","Preis",(c==9)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='npc?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.className="bold";aB.href="npc?id="+aV[0];aB.appendChild(document.createTextNode(aV[1]));var ad=getListTableElement("left",aB);if(aV[3]!=null){addTooltip(ad,aV[3])}if(aV[2]!=null){var ar=document.createElement("span");ar.className="smalltext block";ar.appendChild(document.createTextNode(aV[2]));ad.appendChild(ar)}var aA=getListTableElement("center",document.createTextNode(formatMobLevelString(aV[4],aV[5])));var Q=getListTableElement("center",null);for(S=0;S<aV[6].length;S++){if(S>0&&aV[6][S].length==2){Q.appendChild(document.createTextNode(", "))}if(aV[6][S].length==2){var al=document.createElement("a");al.href="zone?id="+aV[6][S][0];al.appendChild(document.createTextNode(aV[6][S][1]));Q.appendChild(al)}else{Q.appendChild(document.createTextNode(" ("+aV[6][S][0]+" weitere)"))}}var l=getListTableElement("center",document.createTextNode(aV[7]==true?"begrenzt":""));var a=getListTableElement("center",document.createTextNode(aV[8]));var m=getListTableElement("center",null);addPrice(m,aV[9]);appendMultipleChilds(C,[ad,aA,Q,l,a,m]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==2||F==3||F==11||F==20||F==82){if(c==1){sortListLex(aW,1,B)}if(c==7){sortListListLength(aW,7,B)}if(c==10){sortListLex(aW,10,B)}if(c==12){sortListNum(aW,12,B)}if(c==13){sortListNum(aW,13,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,(F!=82)?"45%":"40%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"30%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Reagenzien",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",10,"+((c==10)?aP:0)+","+P+");","Kategorie",(c==10)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",12,"+((c==12)?aP:0)+","+P+");","Fertigkeit",(c==12)?B:-1));if(F==82){C.appendChild(getListContentHeader(false,"5%","javascript:displayTab("+d+",13,"+((c==13)?aP:0)+","+P+");","Score",(c==13)?B:-1))}K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='spell?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.href="spell?id="+aV[0];aB.className="q"+aV[4];if(aB.className=="q1"){aB.className="q1b"}var ax=getItemIcon(aV[2],"spell?id="+aV[0],aV[5],aV[6],aV[7],"medium");aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[5]);var aC=document.createElement("span");aC.className="listelement_iconname_text_table";aC.appendChild(aB);if(aV[3]!=""){var an=document.createElement("span");an.className="listelement_iconname_subtext";an.appendChild(document.createTextNode(aV[3]));aC.appendChild(document.createElement("br"));aC.appendChild(an)}var am=document.createElement("table");var R=document.createElement("tbody");am.appendChild(R);am.cellPadding=0;am.cellSpacing=0;listcontent_tr_name_table_tr=document.createElement("tr");R.appendChild(listcontent_tr_name_table_tr);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.width=44;listcontent_tr_name_table_tr_td.appendChild(ax);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.align="left";listcontent_tr_name_table_tr_td.vAlign="middle";listcontent_tr_name_table_tr_td.appendChild(aC);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);var ad=getListTableElement("left",am);var v;if(browserIsOpera){var aI=document.createElement("table");aI.cellPadding=2;aI.cellSpacing=2;var at=document.createElement("tbody");var n=document.createElement("tr");for(S=0;S<aV[8].length;S++){var V=aV[8][S];var w=document.createElement("td");w.appendChild(getItemIcon(V[1],"item?id="+V[0],V[2],V[3],V[3],"small"));n.appendChild(w)}at.appendChild(n);aI.appendChild(at);v=getListTableElement("left",aI)}else{var aU=document.createElement("div");for(S=0;S<aV[8].length;S++){var V=aV[8][S];aU.appendChild(getItemIcon(V[1],"item?id="+V[0],V[2],V[3],V[3],"small"))}v=getListTableElement("left",aU)}var af=getListTableElement("center",null);var j=document.createElement("a");j.href="spells?category="+aV[9];j.appendChild(document.createTextNode(aV[10]));af.appendChild(j);var ao=document.createElement("div");if(aV[12]>0){var av=document.createElement("div");av.appendChild(document.createTextNode(aV[12]));ao.appendChild(av)}var aD=document.createElement("div");aD.className="smalltext";aD.appendChild(document.createTextNode(aV[11]));ao.appendChild(aD);var aK=getListTableElement("center",ao);var X=null;if(aV[13]!=null){X=getListTableElement("center",document.createTextNode(formatScore(aV[13])))}appendMultipleChilds(C,[ad,v,af,aK,X]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==37){if(c==1){sortListLex(aW,1,B)}if(c==7){sortListListLength(aW,7,B)}if(c==10){sortListLex(aW,10,B)}if(c==12){sortListNum(aW,12,B)}if(c==13){sortListNum(aW,13,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"35%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"30%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Reagenzien",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"13%","javascript:displayTab("+d+",10,"+((c==10)?aP:0)+","+P+");","Kategorie",(c==10)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",12,"+((c==12)?aP:0)+","+P+");","Fertigkeit",(c==12)?B:-1));C.appendChild(getListContentHeader(false,"12%","javascript:displayTab("+d+",13,"+((c==13)?aP:0)+","+P+");","Kosten",(c==13)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='spell?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.href="spell?id="+aV[0];aB.className="q"+aV[4];if(aB.className=="q1"){aB.className="q1b"}var ax=getItemIcon(aV[2],"spell?id="+aV[0],aV[5],aV[6],aV[7],"medium");aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[5]);var aC=document.createElement("span");aC.className="listelement_iconname_text_table";aC.appendChild(aB);if(aV[3]!=""){var an=document.createElement("span");an.className="listelement_iconname_subtext";an.appendChild(document.createTextNode(aV[3]));aC.appendChild(document.createElement("br"));aC.appendChild(an)}var am=document.createElement("table");var R=document.createElement("tbody");am.appendChild(R);am.cellPadding=0;am.cellSpacing=0;listcontent_tr_name_table_tr=document.createElement("tr");R.appendChild(listcontent_tr_name_table_tr);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.width=44;listcontent_tr_name_table_tr_td.appendChild(ax);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.align="left";listcontent_tr_name_table_tr_td.vAlign="middle";listcontent_tr_name_table_tr_td.appendChild(aC);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);var ad=getListTableElement("left",am);var v;if(browserIsOpera){var aI=document.createElement("table");aI.cellPadding=2;aI.cellSpacing=2;var at=document.createElement("tbody");var n=document.createElement("tr");for(S=0;S<aV[8].length;S++){var V=aV[8][S];var w=document.createElement("td");w.appendChild(getItemIcon(V[1],"item?id="+V[0],V[2],V[3],V[3],"small"));n.appendChild(w)}at.appendChild(n);aI.appendChild(at);v=getListTableElement("left",aI)}else{var aU=document.createElement("div");for(S=0;S<aV[8].length;S++){var V=aV[8][S];aU.appendChild(getItemIcon(V[1],"item?id="+V[0],V[2],V[3],V[3],"small"))}v=getListTableElement("left",aU)}var af=getListTableElement("center",null);var j=document.createElement("a");j.href="spells?category="+aV[9];j.appendChild(document.createTextNode(aV[10]));af.appendChild(j);var ao=document.createElement("div");if(aV[12]>0){var av=document.createElement("div");av.appendChild(document.createTextNode(aV[12]));ao.appendChild(av)}var aD=document.createElement("div");aD.className="smalltext";aD.appendChild(document.createTextNode(aV[11]));ao.appendChild(aD);var aK=getListTableElement("center",ao);var aE=getListTableElement("center",null);aE.className="bold";addMoney(aE,aV[13]);appendMultipleChilds(C,[ad,v,af,aK,aE]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==4||F==8||F==21||F==80||F==24){if(c==1){sortListLex(aW,1,B)}if(c==6){sortListNum(aW,6,B)}if(c==7){sortListNum(aW,7,B)}if(c==8){sortListLex(aW,8,B)}if(c==10){sortListNum(aW,10,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,(F!=80)?"50%":"40%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Itemlevel",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Mindeststufe",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Typ",(c==8)?B:-1));if(F==80){C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",10,"+((c==10)?aP:0)+","+P+");","Score",(c==10)?B:-1))}K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='item?id="+aV[0]+"'");C.className="clickable";var A=document.createElement("div");A.className="bold";A.className="q"+aV[3];if(A.className=="q1"){A.className="q1b"}A.style.fontWeight="bold";var aB=document.createElement("a");aB.href="item?id="+aV[0];A.appendChild(getItemIcon(aV[2],"item?id="+aV[0],aV[4],aV[5],aV[5],"medium"));aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[4]);A.appendChild(aB);var ad=getListTableElement("left",A);var H=getListTableElement("center",document.createTextNode(aV[6]));var aM=getListTableElement("center",document.createTextNode(aV[7]));var W=getListTableElement("center",null);getLinkElement(aV[8],"items?category="+aV[9],W);var X=null;if(F==80){X=getListTableElement("center",document.createTextNode(formatScore(aV[10])))}appendMultipleChilds(C,[ad,H,aM,W,X]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==9||F==13||F==7||F==91||F==93||F==94){if(c==1){sortListLex(aW,1,B)}if(c==5){sortListNum(aW,5,B)}if(c==7){sortListNum(aW,7,B)}if(c==8){sortListNum(aW,8,B)}if(c==9){sortListLex(aW,9,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"40%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Itemlevel",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Mindeststufe",(c==8)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",9,"+((c==9)?aP:0)+","+P+");","Typ",(c==9)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",5,"+((c==5)?aP:0)+","+P+");","Chance",(c==5)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='item?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.href="item?id="+aV[0];aB.className="q"+aV[3];if(aB.className=="q1"){aB.className="q1b"}var ax=getItemIcon(aV[2],"item?id="+aV[0],aV[4],1,1,"medium");aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[4]);var aC=document.createElement("span");aC.className="listelement_iconname_text_table";aC.appendChild(aB);var am=document.createElement("table");var R=document.createElement("tbody");am.appendChild(R);am.cellPadding=0;am.cellSpacing=0;listcontent_tr_name_table_tr=document.createElement("tr");R.appendChild(listcontent_tr_name_table_tr);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.width=44;listcontent_tr_name_table_tr_td.appendChild(ax);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.align="left";listcontent_tr_name_table_tr_td.vAlign="middle";listcontent_tr_name_table_tr_td.appendChild(aC);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);var ad=getListTableElement("left",am);var H=getListTableElement("center",document.createTextNode(aV[7]));var aM=getListTableElement("center",document.createTextNode(aV[8]));var W=getListTableElement("center",document.createTextNode(aV[9]));var aY=getListTableElement("center",document.createTextNode(aV[5]+" %"));aY.appendChild(document.createElement("br"));var O=document.createElement("span");O.className="dropcount";O.appendChild(document.createTextNode(aV[6]));aY.appendChild(O);appendMultipleChilds(C,[ad,H,aM,W,aY]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==38||F==90){if(c==1){sortListLex(aW,1,B)}if(c==10){sortListMoney(aW,10,B)}if(c==6){sortListNum(aW,6,B)}if(c==7){sortListNum(aW,7,B)}if(c==8){sortListLex(aW,8,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"40%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Itemlevel",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Mindeststufe",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Typ",(c==8)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",10,"+((c==10)?aP:0)+","+P+");","Preis",(c==10)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='item?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.href="item?id="+aV[0];aB.className="q"+aV[3];if(aB.className=="q1"){aB.className="q1b"}var ax=getItemIcon(aV[2],"item?id="+aV[0],aV[4],aV[5],aV[5],"medium");aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[4]);var aC=document.createElement("span");aC.className="listelement_iconname_text_table";aC.appendChild(aB);var am=document.createElement("table");var R=document.createElement("tbody");am.appendChild(R);am.cellPadding=0;am.cellSpacing=0;listcontent_tr_name_table_tr=document.createElement("tr");R.appendChild(listcontent_tr_name_table_tr);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.width=44;listcontent_tr_name_table_tr_td.appendChild(ax);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.align="left";listcontent_tr_name_table_tr_td.vAlign="middle";listcontent_tr_name_table_tr_td.appendChild(aC);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);var ad=getListTableElement("left",am);var H=getListTableElement("center",document.createTextNode(aV[6]));var aM=getListTableElement("center",document.createTextNode(aV[7]));var W=getListTableElement("center",null);getLinkElement(aV[8],"items?category="+aV[9],W);var m=getListTableElement("center",null);addPrice(m,aV[10]);appendMultipleChilds(C,[ad,H,aM,W,m]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==5||F==10||F==12||F==22||F==35||F==36||F==51||F==52||F==62||F==71||F==83){if(c==1){sortListLex(aW,1,B)}if(c==3){sortListNum(aW,3,B)}if(c==5){sortListNum(aW,5,B)}if(c==8){sortListListLength(aW,8,B)}if(c==6){sortListLex(aW,6,B)}if(c==9){sortListNum(aW,9,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,(F!=71&&F!=83)?"30%":"25%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",3,"+((c==3)?aP:0)+","+P+");","Stufe",(c==3)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",5,"+((c==5)?aP:0)+","+P+");","Fraktion",(c==5)?B:-1));C.appendChild(getListContentHeader(false,"30%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Belohnungen",(c==8)?B:-1));if(F==71){C.appendChild(getListContentHeader(false,"5%","javascript:displayTab("+d+",9,"+((c==8)?aP:0)+","+P+");","Ruf",(c==8)?B:-1))}C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Kategorie",(c==6)?B:-1));if(F==83){C.appendChild(getListContentHeader(false,"5%","javascript:displayTab("+d+",9,"+((c==9)?aP:0)+","+P+");","Score",(c==9)?B:-1))}K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='quest?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.style.fontWeight="bold";aB.href="quest?id="+aV[0];aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[2]);var aA=getListTableElement("center",document.createTextNode(aV[3]));var u=document.createElement("div");u.appendChild(document.createTextNode(aV[4]));u.className="lilbitsmallertext";aA.appendChild(u);var ad=getListTableElement("left",aB);var aw=getListTableElement("center",null);if((aV[5]&1)!=0){var ab=document.createElement("img");ab.src="images/faction_alliance.png";aw.appendChild(ab)}if((aV[5]&2)!=0){var aq=document.createElement("img");aq.src="images/faction_horde.png";aw.appendChild(aq)}var L=getListTableElement("center",null);var az;var y=document.createElement("table");y.border=0;y.cellPadding=0;y.cellSpacing=0;var aJ=document.createElement("tbody");var t=document.createElement("tr");if(aV[8][0].length>0){for(S=0;S<aV[8][0].length;S++){az=document.createElement("td");listcontent_tr_rewards_content_table=document.createElement("table");listcontent_tr_rewards_content_table.width=32;listcontent_tr_rewards_content_table.border=0;listcontent_tr_rewards_content_table.cellPadding=0;listcontent_tr_rewards_content_table.cellSpacing=0;listcontent_tr_rewards_content_table_tbody=document.createElement("tbody");listcontent_tr_rewards_content_table_tr=document.createElement("tr");listcontent_tr_rewards_content_table_td=document.createElement("td");listcontent_tr_rewards_content_table_td.align="left";addItemIcon(listcontent_tr_rewards_content_table_td,aV[8][0][S][1],"item?id="+aV[8][0][S][0],aV[8][0][S][2],aV[8][0][S][3],aV[8][0][S][3],"small");listcontent_tr_rewards_content_table_tr.appendChild(listcontent_tr_rewards_content_table_td);listcontent_tr_rewards_content_table_tbody.appendChild(listcontent_tr_rewards_content_table_tr);listcontent_tr_rewards_content_table.appendChild(listcontent_tr_rewards_content_table_tbody);az.appendChild(listcontent_tr_rewards_content_table);t.appendChild(az)}}if(aV[8][1].length>0){var aj;if(aV[8][0].length>0){aj=document.createTextNode(" und eines von:")}else{aj=document.createTextNode("eines von: ")}az=document.createElement("td");az.appendChild(aj);t.appendChild(az);for(S=0;S<aV[8][1].length;S++){az=document.createElement("td");listcontent_tr_rewards_content_table=document.createElement("table");listcontent_tr_rewards_content_table.width=32;listcontent_tr_rewards_content_table.border=0;listcontent_tr_rewards_content_table.cellPadding=0;listcontent_tr_rewards_content_table.cellSpacing=0;listcontent_tr_rewards_content_table_tbody=document.createElement("tbody");listcontent_tr_rewards_content_table_tr=document.createElement("tr");listcontent_tr_rewards_content_table_td=document.createElement("td");listcontent_tr_rewards_content_table_td.align="left";addItemIcon(listcontent_tr_rewards_content_table_td,aV[8][1][S][1],"item?id="+aV[8][1][S][0],aV[8][1][S][2],aV[8][1][S][3],aV[8][1][S][3],"small");listcontent_tr_rewards_content_table_tr.appendChild(listcontent_tr_rewards_content_table_td);listcontent_tr_rewards_content_table_tbody.appendChild(listcontent_tr_rewards_content_table_tr);listcontent_tr_rewards_content_table.appendChild(listcontent_tr_rewards_content_table_tbody);az.appendChild(listcontent_tr_rewards_content_table);t.appendChild(az)}}aJ.appendChild(t);y.appendChild(aJ);L.appendChild(y);var af=getListTableElement("center",null);getLinkElement(aV[6],"quests?category="+aV[7],af);var N=null;if(F==71){N=getListTableElement("center",document.createTextNode(aV[9]))}var X=null;if(F==83){X=getListTableElement("center",document.createTextNode(formatScore(aV[9])))}appendMultipleChilds(C,[ad,aA,aw,L,N,af,X]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==6||F==14||F==15||F==16){if(c==1){sortListLex(aW,1,B)}if(c==4){sortListNum(aW,4,B)}if(c==6){sortListLex(aW,6,B)}if(c==7){sortListNum(aW,7,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"50%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",4,"+((c==4)?aP:0)+","+P+");","Stufe",(c==4)?B:-1));C.appendChild(getListContentHeader(false,"30%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Aufenthaltsort",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Chance",(c==7)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='npc?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.className="bold";aB.href="npc?id="+aV[0];aB.appendChild(document.createTextNode(aV[1]));var ad=getListTableElement("left",aB);if(aV[2]!=null){var ar=document.createElement("span");ar.className="smalltext block";ar.appendChild(document.createTextNode(aV[2]));ad.appendChild(ar)}if(aV[3]!=null){addTooltip(ad,aV[3])}var aA=getListTableElement("center",document.createTextNode(formatMobLevelString(aV[4],aV[5])));var Q=getListTableElement("center",null);for(S=0;S<aV[6].length;S++){if(S>0&&aV[6][S].length==2){Q.appendChild(document.createTextNode(", "))}if(aV[6][S].length==2){var al=document.createElement("a");al.href="zone?id="+aV[6][S][0];al.appendChild(document.createTextNode(aV[6][S][1]));Q.appendChild(al)}else{Q.appendChild(document.createTextNode(" ("+aV[6][S][0]+" weitere)"))}}var aY=getListTableElement("center",document.createTextNode(aV[7]+" %"));aY.appendChild(document.createElement("br"));var O=document.createElement("span");O.className="dropcount";O.appendChild(document.createTextNode(aV[8]));aY.appendChild(O);appendMultipleChilds(C,[ad,aA,Q,aY]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==30||F==31||F==32||F==33||F==34){if(c==1){sortListLex(aW,1,B)}if(c==5){sortListNum(aW,5,B)}if(c==6){sortListNum(aW,6,B)}if(c==7){sortListLex(aW,7,B)}if(c==8){sortListNum(aW,8,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"50%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",5,"+((c==5)?aP:0)+","+P+");","Itemlevel",(c==5)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Mindeststufe",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Typ",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Chance",(c==8)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='item?id="+aV[0]+"'");C.className="clickable";var A=document.createElement("div");A.className="bold";A.className="q"+aV[3];if(A.className=="q1"){A.className="q1b"}A.style.fontWeight="bold";var aB=document.createElement("a");aB.href="item?id="+aV[0];A.appendChild(getItemIcon(aV[2],"item?id="+aV[0],aV[4],1,1,"medium"));aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[4]);A.appendChild(aB);var ad=getListTableElement("left",A);var H=getListTableElement("center",document.createTextNode(aV[5]));var aM=getListTableElement("center",document.createTextNode(aV[6]));var W=getListTableElement("center",document.createTextNode(aV[7]));var aY=getListTableElement("center",document.createTextNode(aV[8]+" %"));aY.appendChild(document.createElement("br"));var O=document.createElement("span");O.className="dropcount";O.appendChild(document.createTextNode(aV[9]));aY.appendChild(O);appendMultipleChilds(C,[ad,H,aM,W,aY]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==64||F==65||F==66||F==67||F==68||F==69){if(c==1){sortListLex(aW,1,B)}if(c==5){sortListNum(aW,5,B)}if(c==6){sortListNum(aW,6,B)}if(c==7){sortListLex(aW,7,B)}if(c==8){sortListLex(aW,8,B)}if(c==9){sortListNum(aW,9,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"40%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",5,"+((c==5)?aP:0)+","+P+");","Itemlevel",(c==5)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Mindeststufe",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"18%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Quelle",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"12%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Typ",(c==8)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",9,"+((c==9)?aP:0)+","+P+");","Chance",(c==9)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='item?id="+aV[0]+"'");C.className="clickable";var A=document.createElement("div");A.className="bold";A.className="q"+aV[3];if(A.className=="q1"){A.className="q1b"}A.style.fontWeight="bold";var aB=document.createElement("a");aB.href="item?id="+aV[0];A.appendChild(getItemIcon(aV[2],"item?id="+aV[0],aV[4],1,1,"medium"));aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[4]);A.appendChild(aB);var ad=getListTableElement("left",A);var H=getListTableElement("center",document.createTextNode(aV[5]));var aM=getListTableElement("center",document.createTextNode(aV[6]));var ak=getListTableElement("center",null);if(aV[7][0]!=""){if(aV[7][1]!=""){getLinkElement(aV[7][0],aV[7][1],ak)}else{ak.appendChild(document.createTextNode(aV[7][0]))}}if(aV[7][2]!=""){ak.appendChild(document.createElement("br"));var r=document.createElement("span");r.className="smalltext";getLinkElement(aV[7][2],aV[7][3],r);ak.appendChild(r)}var W=getListTableElement("center",document.createTextNode(aV[8]));var aY=getListTableElement("center",document.createTextNode(aV[9]+" %"));aY.appendChild(document.createElement("br"));var O=document.createElement("span");O.className="dropcount";O.appendChild(document.createTextNode(aV[10]));aY.appendChild(O);appendMultipleChilds(C,[ad,H,aM,ak,W,aY]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==17||F==18||F==19){if(c==1){sortListLex(aW,1,B)}if(c==3){sortListListLength(aW,3,B)}if(c==4){sortListLex(aW,4,B)}if(c==6){sortListNum(aW,6,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"30%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"50%","javascript:displayTab("+d+",3,"+((c==3)?aP:0)+","+P+");","Zone",(c==3)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",4,"+((c==4)?aP:0)+","+P+");","Typ",(c==4)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Chance",(c==6)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='object?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.className="bold";aB.href="object?id="+aV[0];aB.appendChild(document.createTextNode(aV[1]));var ad=getListTableElement("left",aB);if(aV[2]!=null){addTooltip(ad,aV[2])}var Q=getListTableElement("center",null);for(S=0;S<aV[3].length;S++){if(S>0&&aV[3][S].length==2){Q.appendChild(document.createTextNode(", "))}if(aV[3][S].length==2){var al=document.createElement("a");al.href="zone?id="+aV[3][S][0];al.appendChild(document.createTextNode(aV[3][S][1]));Q.appendChild(al)}else{Q.appendChild(document.createTextNode(" ("+aV[3][S][0]+" weitere)"))}}var af=getListTableElement("center",null);getLinkElement(aV[4],"objects?category="+aV[5],af);var aY=getListTableElement("center",document.createTextNode(aV[6]+" %"));aY.appendChild(document.createElement("br"));var O=document.createElement("span");O.className="dropcount";O.appendChild(document.createTextNode(aV[7]));aY.appendChild(O);appendMultipleChilds(C,[ad,Q,af,aY]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==50||F==53||F==54){if(c==1){sortListLex(aW,1,B)}if(c==5){sortListNum(aW,5,B)}if(c==6){sortListNum(aW,6,B)}if(c==7){sortListLex(aW,7,B)}if(c==9){sortListNum(aW,9,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"50%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",5,"+((c==5)?aP:0)+","+P+");","Itemlevel",(c==5)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Mindeststufe",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Typ",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",9,"+((c==9)?aP:0)+","+P+");","Chance",(c==9)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='item?id="+aV[0]+"'");C.className="clickable";var A=document.createElement("div");A.className="bold";A.className="q"+aV[3];if(A.className=="q1"){A.className="q1b"}A.style.fontWeight="bold";var aB=document.createElement("a");aB.href="item?id="+aV[0];A.appendChild(getItemIcon(aV[2],"item?id="+aV[0],aV[4],1,1,"medium"));aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[4]);A.appendChild(aB);var ad=getListTableElement("left",A);var H=getListTableElement("center",document.createTextNode(aV[5]));var aM=getListTableElement("center",document.createTextNode(aV[6]));var W=getListTableElement("center",null);getLinkElement(aV[7],"npcs?category="+aV[8],W);var aY=getListTableElement("center",document.createTextNode(aV[9]+" %"));aY.appendChild(document.createElement("br"));var O=document.createElement("span");O.className="dropcount";O.appendChild(document.createTextNode(aV[10]));aY.appendChild(O);appendMultipleChilds(C,[ad,H,aM,W,aY]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==61||F==85){if(c==1){sortListLex(aW,1,B)}if(c==2){sortListListLength(aW,2,B)}if(c==4){sortListLex(aW,4,B)}if(c==6){sortListNum(aW,6,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"30%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,(F!=85)?"55%":"50%","javascript:displayTab("+d+",2,"+((c==2)?aP:0)+","+P+");","Zone",(c==2)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",4,"+((c==4)?aP:0)+","+P+");","Typ",(c==4)?B:-1));if(F==85){C.appendChild(getListContentHeader(false,"5%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Score",(c==6)?B:-1))}K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='object?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.className="bold";aB.href="object?id="+aV[0];aB.appendChild(document.createTextNode(aV[1]));var ad=getListTableElement("left",aB);if(aV[2]!=null){addTooltip(ad,aV[2])}var Q=getListTableElement("center",null);for(S=0;S<aV[3].length;S++){if(S>0&&aV[3][S].length==2){Q.appendChild(document.createTextNode(", "))}if(aV[3][S].length==2){var al=document.createElement("a");al.href="zone?id="+aV[3][S][0];al.appendChild(document.createTextNode(aV[3][S][1]));Q.appendChild(al)}else{Q.appendChild(document.createTextNode(" ("+aV[3][S][0]+" weitere)"))}}var af=getListTableElement("center",null);getLinkElement(aV[4],"objects?category="+aV[5],af);var X=null;if(F==85){X=getListTableElement("center",document.createTextNode(formatScore(aV[6])))}appendMultipleChilds(C,[ad,Q,af,X]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==63){if(c==1){sortListLex(aW,1,B)}if(c==5){sortListNum(aW,5,B)}if(c==6){sortListNum(aW,6,B)}if(c==7){sortListLex(aW,7,B)}if(c==9){sortListNum(aW,9,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"50%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",5,"+((c==5)?aP:0)+","+P+");","Itemlevel",(c==5)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Mindeststufe",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Typ",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",9,"+((c==9)?aP:0)+","+P+");","Chance",(c==9)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='item?id="+aV[0]+"'");C.className="clickable";var A=document.createElement("div");A.className="bold";A.className="q"+aV[3];if(A.className=="q1"){A.className="q1b"}A.style.fontWeight="bold";var aB=document.createElement("a");aB.href="item?id="+aV[0];A.appendChild(getItemIcon(aV[2],"item?id="+aV[0],aV[4],1,1,"medium"));aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[4]);A.appendChild(aB);var ad=getListTableElement("left",A);var H=getListTableElement("center",document.createTextNode(aV[5]));var aM=getListTableElement("center",document.createTextNode(aV[6]));var W=getListTableElement("center",null);getLinkElement(aV[7],"items?category="+aV[8],W);var aY=getListTableElement("center",document.createTextNode(aV[9]+" %"));aY.appendChild(document.createElement("br"));var O=document.createElement("span");O.className="dropcount";O.appendChild(document.createTextNode(aV[10]));aY.appendChild(O);appendMultipleChilds(C,[ad,H,aM,W,aY]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==70){if(c==1){sortListLex(aW,1,B)}if(c==6){sortListNum(aW,6,B)}if(c==7){sortListNum(aW,7,B)}if(c==8){sortListNum(aW,8,B)}if(c==9){sortListLex(aW,9,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"40%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Itemlevel",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Mindeststufe",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Ruf",(c==8)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",9,"+((c==9)?aP:0)+","+P+");","Typ",(c==9)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='item?id="+aV[0]+"'");C.className="clickable";var A=document.createElement("div");A.className="bold";A.className="q"+aV[3];if(A.className=="q1"){A.className="q1b"}A.style.fontWeight="bold";var aB=document.createElement("a");aB.href="item?id="+aV[0];A.appendChild(getItemIcon(aV[2],"item?id="+aV[0],aV[4],aV[5],aV[5],"medium"));aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[4]);A.appendChild(aB);var ad=getListTableElement("left",A);var H=getListTableElement("center",document.createTextNode(aV[6]));var aM=getListTableElement("center",document.createTextNode(aV[7]));var N=getListTableElement("center",null);var aR="";switch(aV[8]){case 0:aR="Hasserfüllt";break;case 1:aR="Feindselig";break;case 2:aR="Unfreundlich";break;case 3:aR="Neutral";break;case 4:aR="Freundlich";break;case 5:aR="Wohlwollend";break;case 6:aR="Respektvoll";break;case 7:aR="Ehrfürchtig";break}N.appendChild(document.createTextNode(aR));var W=getListTableElement("center",null);getLinkElement(aV[9],"items?category="+aV[10],W);appendMultipleChilds(C,[ad,H,aM,N,W]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==81){if(c==1){sortListLex(aW,1,B)}if(c==3){sortListNum(aW,3,B)}if(c==5){sortListNum(aW,5,B)}if(c==6){sortListLex(aW,6,B)}if(c==7){sortListLex(aW,7,B)}if(c==9){sortListNum(aW,9,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"30%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",3,"+((c==3)?aP:0)+","+P+");","Itemlevel",(c==3)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",5,"+((c==5)?aP:0)+","+P+");","Setteile",(c==5)?B:-1));C.appendChild(getListContentHeader(false,"30%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Klassen",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Kategorie",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"5%","javascript:displayTab("+d+",9,"+((c==9)?aP:0)+","+P+");","Score",(c==9)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='npc?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.className="bold";aB.href="itemset?id="+aV[0];aB.appendChild(document.createTextNode(aV[1]));var ad=getListTableElement("left",aB);if(aV[2]!=""){var ar=document.createElement("span");ar.className="smalltext block";ar.appendChild(document.createTextNode(aV[2]));ad.appendChild(ar)}var aA=getListTableElement("center",document.createTextNode(formatMobLevelString(aV[3],aV[4])));var Y=getListTableElement("center",document.createTextNode(aV[5]));var Z=getListTableElement("center",document.createTextNode(aV[6]));var af=getListTableElement("center",null);getLinkElement(aV[7],"itemsets?category="+aV[8],af);var X=getListTableElement("center",document.createTextNode(formatScore(aV[9])));appendMultipleChilds(C,[ad,aA,Y,Z,af,X]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==86){if(c==1){sortListLex(aW,1,B)}if(c==2){sortListNum(aW,2,B)}if(c==4){sortListLex(aW,4,B)}if(c==5){sortListLex(aW,5,B)}if(c==7){sortListNum(aW,7,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"60%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",2,"+((c==2)?aP:0)+","+P+");","Stufe",(c==2)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",4,"+((c==4)?aP:0)+","+P+");","Territorium",(c==4)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",5,"+((c==5)?aP:0)+","+P+");","Kategorie",(c==5)?B:-1));C.appendChild(getListContentHeader(false,"5%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Score",(c==7)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='zone?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.className="bold";aB.href="zone?id="+aV[0];aB.appendChild(document.createTextNode(aV[1]));var ad=getListTableElement("left",aB);var aA=getListTableElement("center",document.createTextNode(formatMobLevelString(aV[2],aV[3])));var aO=getListTableElement("center",document.createTextNode(aV[4]));var af=getListTableElement("center",null);getLinkElement(aV[5],"zones?category="+aV[6],af);var X=getListTableElement("center",document.createTextNode(formatScore(aV[7])));appendMultipleChilds(C,[ad,aA,aO,af,X]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==87){if(c==1){sortListLex(aW,1,B)}if(c==2){sortListLex(aW,2,B)}if(c==3){sortListNum(aW,3,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"75%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"20%","javascript:displayTab("+d+",2,"+((c==2)?aP:0)+","+P+");","Gruppe",(c==2)?B:-1));C.appendChild(getListContentHeader(false,"5%","javascript:displayTab("+d+",3,"+((c==3)?aP:0)+","+P+");","Score",(c==3)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='faction?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.className="bold";aB.href="faction?id="+aV[0];aB.appendChild(document.createTextNode(aV[1]));var ad=getListTableElement("left",aB);var ap=getListTableElement("center",document.createTextNode(aV[2]));var X=getListTableElement("center",document.createTextNode(formatScore(aV[3])));appendMultipleChilds(C,[ad,ap,X]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==88||F==92){if(c==1){sortListLex(aW,1,B)}if(c==5){sortListNum(aW,5,B)}if(c==6){sortListListLength(aW,6,B)}if(c==7){sortListNum(aW,7,B)}if(c==8){sortListLex(aW,8,B)}if(c==10){sortListNum(aW,10,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"50%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"10%","javascript:displayTab("+d+",5,"+((c==5)?aP:0)+","+P+");","Fraktion",(c==5)?B:-1));C.appendChild(getListContentHeader(false,"15%","javascript:displayTab("+d+",6,"+((c==6)?aP:0)+","+P+");","Zone",(c==6)?B:-1));C.appendChild(getListContentHeader(false,"8%","javascript:displayTab("+d+",7,"+((c==7)?aP:0)+","+P+");","Punkte",(c==7)?B:-1));C.appendChild(getListContentHeader(false,"12%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Kategorie",(c==8)?B:-1));if(F==88){C.appendChild(getListContentHeader(false,"5%","javascript:displayTab("+d+",10,"+((c==10)?aP:0)+","+P+");","Score",(c==10)?B:-1))}K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='achievement?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.href="achievement?id="+aV[0];aB.className="q1b";var ax=getItemIcon(aV[3],"achievement?id="+aV[0],aV[4],1,1,"medium");aB.appendChild(document.createTextNode(aV[1]));var aC=document.createElement("span");aC.className="listelement_iconname_text_table";aC.appendChild(aB);if(aV[2]!=""){var an=document.createElement("span");an.className="listelement_iconname_subtext";an.appendChild(document.createTextNode(aV[2]));aC.appendChild(document.createElement("br"));aC.appendChild(an)}var am=document.createElement("table");var R=document.createElement("tbody");am.appendChild(R);am.cellPadding=0;am.cellSpacing=0;listcontent_tr_name_table_tr=document.createElement("tr");R.appendChild(listcontent_tr_name_table_tr);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.width=44;listcontent_tr_name_table_tr_td.appendChild(ax);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.align="left";listcontent_tr_name_table_tr_td.vAlign="middle";listcontent_tr_name_table_tr_td.appendChild(aC);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);var ad=getListTableElement("left",am);var aw=getListTableElement("center",null);if((aV[5]&1)!=0){var ab=document.createElement("img");ab.src="images/faction_alliance.png";aw.appendChild(ab)}if((aV[5]&2)!=0){var aq=document.createElement("img");aq.src="images/faction_horde.png";aw.appendChild(aq)}var Q=getListTableElement("center",null);for(S=0;S<aV[6].length;S++){if(S>0&&aV[6][S].length==2){Q.appendChild(document.createTextNode(", "))}if(aV[6][S].length==2){var al=document.createElement("a");al.href="zone?id="+aV[6][S][0];al.appendChild(document.createTextNode(aV[6][S][1]));Q.appendChild(al)}else{Q.appendChild(document.createTextNode(" ("+aV[6][S][0]+" weitere)"))}}var o=getListTableElement("center",document.createTextNode(aV[7]));var aG=document.createElement("a");aG.href="achievements?category="+aV[9];aG.appendChild(document.createTextNode(aV[8]));var af=getListTableElement("center",aG);var X=null;if(F==88){X=getListTableElement("center",document.createTextNode(formatScore(aV[10])))}appendMultipleChilds(C,[ad,aw,Q,o,af,X]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}if(F==95){if(c==1){sortListLex(aW,1,B)}if(c==8){sortListListLength(aW,8,B)}ae=getListContentTable();var K=document.createElement("thead");var C=document.createElement("tr");C.appendChild(getListContentHeader(true,"76%","javascript:displayTab("+d+",1,"+((c==1)?aP:0)+","+P+");","Name",(c==1)?B:-1));C.appendChild(getListContentHeader(false,"24%","javascript:displayTab("+d+",8,"+((c==8)?aP:0)+","+P+");","Schwierigkeitsgrad",(c==8)?B:-1));K.appendChild(C);ae.appendChild(K);var D=document.createElement("tbody");D.className="listbody";for(T=0;T<aF;T++){var aV=aW[T+P];C=document.createElement("tr");C.onclick=new Function("document.location.href='spell?id="+aV[0]+"'");C.className="clickable";var aB=document.createElement("a");aB.href="spell?id="+aV[0];aB.className="q"+aV[4];if(aB.className=="q1"){aB.className="q1b"}var ax=getItemIcon(aV[2],"spell?id="+aV[0],aV[5],aV[6],aV[7],"medium");aB.appendChild(document.createTextNode(aV[1]));addTooltip(aB,aV[5]);var aC=document.createElement("span");aC.className="listelement_iconname_text_table";aC.appendChild(aB);if(aV[3]!=""){var an=document.createElement("span");an.className="listelement_iconname_subtext";an.appendChild(document.createTextNode(aV[3]));aC.appendChild(document.createElement("br"));aC.appendChild(an)}var am=document.createElement("table");var R=document.createElement("tbody");am.appendChild(R);am.cellPadding=0;am.cellSpacing=0;listcontent_tr_name_table_tr=document.createElement("tr");R.appendChild(listcontent_tr_name_table_tr);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.width=44;listcontent_tr_name_table_tr_td.appendChild(ax);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.align="left";listcontent_tr_name_table_tr_td.vAlign="middle";listcontent_tr_name_table_tr_td.appendChild(aC);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);var ad=getListTableElement("left",am);var z;if(browserIsOpera){var q=document.createElement("table");q.cellPadding=2;q.cellSpacing=2;var aQ=document.createElement("tbody");var ai=document.createElement("tr");for(S=0;S<aV[8].length;S++){var au=document.createElement("td");au.appendChild(getItemIcon("images/difficulty/"+aV[8][S][0]+".jpg",null,aV[8][S][1],1,1,"small"));ai.appendChild(au)}aQ.appendChild(ai);q.appendChild(aQ);z=getListTableElement("left",q)}else{var f=document.createElement("div");for(S=0;S<aV[8].length;S++){f.appendChild(getItemIcon("images/difficulty/"+aV[8][S][0]+".jpg",null,aV[8][S][1],1,1,"small"))}z=getListTableElement("left",f)}appendMultipleChilds(C,[ad,z]);D.appendChild(C)}ae.appendChild(D);ae.id="listcontent";aT.appendChild(ae)}var aS=false;if(F==100){commenttabid=d;if(commentdata==null){displayLoadingScreen();postAJAXCommentRequest(identifier,identifiertype);aS=true}else{var aN=document.getElementById("listheader");var ac=document.getElementById("listfooter");removeAllChilds(aN.firstChild.firstChild);removeAllChilds(ac.firstChild.firstChild);var J=(commentdata.length==1)?"":"e";var aL=commentdata.length+" Kommentar"+J+" vorhanden";if(loggedinas==null){aL=aL+" - ";aN.firstChild.firstChild.appendChild(document.createTextNode(aL));var U=document.createElement("a");U.href="login?dropsite="+getDropsite(identifiertype)+"%3Fid%3D"+identifier;U.appendChild(document.createTextNode("logge dich ein"));aN.firstChild.firstChild.appendChild(U);aN.firstChild.firstChild.appendChild(document.createTextNode(" und schreibe einen eigenen!"))}else{aN.firstChild.firstChild.appendChild(document.createTextNode(aL))}displayComments(aT)}}if(F==101){screenshottabid=d;if(screenshotdata==null){displayLoadingScreen();postAJAXScreenshotRequest(identifier,identifiertype);aS=true}else{var aN=document.getElementById("listheader");var ac=document.getElementById("listfooter");removeAllChilds(aN.firstChild.firstChild);removeAllChilds(ac.firstChild.firstChild);var J=(screenshotdata.length==1)?"":"s";var aL=screenshotdata.length+" Screenshot"+J+" vorhanden";if(loggedinas==null){aL=aL+" - ";aN.firstChild.firstChild.appendChild(document.createTextNode(aL));var U=document.createElement("a");U.href="login?dropsite="+getDropsite(identifiertype)+"%3Fid%3D"+identifier;U.appendChild(document.createTextNode("logge dich ein"));aN.firstChild.firstChild.appendChild(U);aN.firstChild.firstChild.appendChild(document.createTextNode(" und lade einen hoch!"))}else{aN.firstChild.firstChild.appendChild(document.createTextNode(aL))}displayScreenshots(aT)}}if(F==110){modelviewertabid=d;var aN=document.getElementById("listheader");var ac=document.getElementById("listfooter");removeAllChilds(aN.firstChild.firstChild);removeAllChilds(ac.firstChild.firstChild);var aH=aW;var M=document.createElement("a");M.href="static_help_modelviewer";M.target="_blank";M.appendChild(document.createTextNode("Was ist das?"));aN.firstChild.firstChild.appendChild(M);var ay;if(identifiertype==1){ay="item"}if(identifiertype==3){ay="itemset"}if(identifiertype==4){ay="npc"}if(identifiertype==6){ay="object"}displayModelViewer(ay,aH,identifier,aT)}selectedTab=d;tabSortBy=-1;tabSortDirection=-1;tabStartAt=-1;if(F<100){tabSortBy=c;tabSortDirection=B;tabStartAt=P;var aN=document.getElementById("listheader");var ac=document.getElementById("listfooter");removeAllChilds(aN.firstChild.firstChild);if(P>0){var E=0;var aX=document.createElement("a");aX.href="javascript:displayTab("+d+","+c+","+B+","+E+");";aX.appendChild(document.createTextNode("|<"));aN.firstChild.firstChild.appendChild(aX);aN.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"));if(P-50*5>=0){var G=P-50*5;var aa=document.createElement("a");aa.href="javascript:displayTab("+d+","+c+","+B+","+G+");";aa.appendChild(document.createTextNode("<<"));aN.firstChild.firstChild.appendChild(aa);aN.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"))}var I=P-50;var p=document.createElement("a");p.href="javascript:displayTab("+d+","+c+","+B+","+I+");";p.appendChild(document.createTextNode("<"));aN.firstChild.firstChild.appendChild(p);aN.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"))}var s=(P+1)+" - "+(P+aF)+" von "+x;aN.firstChild.firstChild.appendChild(document.createTextNode(s));aN.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"));if(P+50<x){var h=P+50;var ag=document.createElement("a");ag.href="javascript:displayTab("+d+","+c+","+B+","+h+");";ag.appendChild(document.createTextNode(">"));aN.firstChild.firstChild.appendChild(ag);aN.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"));if(P+50*5<x){var g=P+50*5;var b=document.createElement("a");b.href="javascript:displayTab("+d+","+c+","+B+","+g+");";b.appendChild(document.createTextNode(">>"));aN.firstChild.firstChild.appendChild(b);aN.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"))}var e=x-(x%50);if(e==x){e=e-50}var ah=document.createElement("a");ah.href="javascript:displayTab("+d+","+c+","+B+","+e+");";ah.appendChild(document.createTextNode(">|"));aN.firstChild.firstChild.appendChild(ah)}ac.firstChild.replaceChild(aN.firstChild.firstChild.cloneNode(true),ac.firstChild.firstChild)}if(aS==false&&preventTabSaving==false){saveTabSettingsToURL()}if(aS==false){preventTabSaving=false}checkWindowSize()}function setActiveTab(a){var c;var b=document.getElementById("tablist");var d=0;if(b.childNodes[0]==null){return}if(b.childNodes[0].nodeName!="LI"){d=1}for(c=d;c<b.childNodes.length;c++){b.childNodes[c].className=null}b.childNodes[a+d].className="chosentab"}function formatMobLevelString(a,b){if(a==-1||b==-1){return"Boss"}if(a==b){return a}else{return a+" - "+b}}var sortListCol=0;function sortListLex(b,a,c){sortListCol=a;b.sort(lexicalListCompare);if(c!=0){b.reverse()}}function lexicalListCompare(d,c){var h,e;if(typeof d[sortListCol]=="string"){h=d[sortListCol].toLowerCase()}else{if(d.length>0){if(typeof d[sortListCol][0]=="string"){h=d[sortListCol][0].toLowerCase()}else{if(typeof d[sortListCol][0][1]=="string"){h=d[sortListCol][0][1].toLowerCase()}else{h=""}}}}if(typeof c[sortListCol]=="string"){e=c[sortListCol].toLowerCase()}else{if(c.length>0){if(typeof c[sortListCol][0]=="string"){e=c[sortListCol][0].toLowerCase()}else{if(typeof c[sortListCol][0][1]=="string"){e=c[sortListCol][0][1].toLowerCase()}else{e=""}}}}var l=h.length;if(e.length<l){l=e.length}var g;for(g=0;g<l;g++){var j=h.charCodeAt(g);var f=e.charCodeAt(g);if(j>f){return 1}else{if(f>j){return -1}}}if(h.length<e.length){return -1}else{if(e.length<h.length){return 1}else{return 0}}}function sortListNum(b,a,c){sortListCol=a;b.sort(numericalListCompare);if(c!=0){b.reverse()}}function numericalListCompare(d,c){var f=d[sortListCol];var e=c[sortListCol];return f-e}function sortListListLength(b,a,c){sortListCol=a;b.sort(listLengthListCompare);if(c!=0){b.reverse()}}function listLengthListCompare(d,c){var f=d[sortListCol].length;var e=c[sortListCol].length;return f-e}function sortListMoney(b,a,c){sortListCol=a;b.sort(listMoneyCompare);if(c!=0){b.reverse()}}function listMoneyCompare(d,c){var f=d[sortListCol][0][3];var e=c[sortListCol][0][3];return f-e}function formatScore(a){return(Math.round(a*1000)/10)+"%"}function renderExtInfo(){if(extinfodata.length==0){return}var c,b;var a=new Array();for(c=0;c<extinfodata.length;c++){var e=false;for(b=0;b<a.length;b++){if(a[b]==extinfodata[c][2]){e=true;break}}if(!e){a.push(extinfodata[c][2])}}for(b=0;b<a.length;b++){var g=document.getElementById("extinfocontainer"+a[b]);var d=document.createElement("ul");for(c=0;c<extinfodata.length;c++){if(extinfodata[c][2]==a[b]){var f=document.createElement("li");f.appendChild(renderSpecificExtInfo(c,extinfodata[c][0],extinfodata[c][1],extinfodata[c][3],extinfodata[c][4]));d.appendChild(f)}}g.appendChild(d);g.appendChild(document.createElement("br"));if(extinfodata.length==1&&extinfodata[0][0]<=2&&extinfodata[0][4].length==1&&extinfodata[0][4][0][4].length>0){displayExtInfoMap(0,0,extinfodata[0][4][0][3])}}}function renderSpecificExtInfo(d,j,h,c,f){var g;var a=document.createElement("div");a.appendChild(document.createTextNode(h+" "));if(j==1||j==2||j==4){for(g=0;g<f.length;g++){var b=document.createElement("a");if(f[g][4].length>0){b.href="javascript:displayExtInfoMap("+d+","+g+", "+((f[g][3]==true)?"true":"false")+",'"+c+"')"}else{b.href="zone?id="+f[g][0]}var m=f[g][1];if(f[g][2]>0){m=m+" - Areal "+f[g][2]}b.appendChild(document.createTextNode(m));a.appendChild(b);if(f[g][4].length>0){a.appendChild(document.createTextNode(" ("+f[g][4].length+")"))}if(g<f.length-1){if(g==f.length-2){a.appendChild(document.createTextNode(" und "))}else{a.appendChild(document.createTextNode(", "))}}}}if(j==3){a.className="bold";if(f.length>0){var l=document.createElement("a");l.href=f[0];l.appendChild(document.createTextNode("["+f[1]+"]"));l.className="q"+f[2]+((f[2]==1)?"b":"");addTooltip(l,f[3]);a.appendChild(l)}}if(j==5){a.className="bold";if(f.length>0){var l=document.createElement("a");l.href=f[0];l.appendChild(document.createTextNode("["+f[1]+"]"));addTooltip(l,f[2]);a.appendChild(l)}}var e=document.createElement("div");e.id="extinfodetailscontainer"+d;a.appendChild(e);return a}function displayExtInfoMap(u,f,q,z){var B=(windowAtFullSize()==true)?750:500;var o=(windowAtFullSize()==true)?500:330;var C=extinfodata[u][4];closeExtInfoMap(u);var r=document.getElementById("extinfodetailscontainer"+u);var x=q;if(q==true){if(getCookie("noFlashMap")=="true"){q=false}}var y=document.createElement("table");y.cellPadding=0;y.cellSpacing=0;y.border=0;y.className="extinfomapmenu";var b=document.createElement("tbody");var A=document.createElement("tr");var d=document.createElement("td");d.width="60%";d.className="extinfomapmenubar";if(x){var l=document.createElement("a");if(!q){l.href="javascript:toggleFlashMap(true,"+u+","+f+");";l.appendChild(document.createTextNode("nutze erweiterte, Flash-basierte Karte"))}else{l.href="javascript:toggleFlashMap(false,"+u+","+f+");";l.appendChild(document.createTextNode("nutze einfache Karte ohne Flash"))}d.appendChild(l)}else{d.appendChild(document.createTextNode("keine Flash-basierte Karte für diese Zone verfügbar"))}A.appendChild(d);d=document.createElement("td");d.align="right";var l=document.createElement("a");d.className="extinfomapmenubar";l.href="javascript:closeExtInfoMap("+u+");";l.appendChild(document.createTextNode("Karte schließen"));d.appendChild(l);A.appendChild(d);b.appendChild(A);A=document.createElement("tr");d=document.createElement("td");d.colSpan=2;if(q==true){var h=document.createElement("div");h.id="extinfodetailscontainer"+u+"flashmap";h.className=(windowAtFullSize()==true)?"extinfomap":"extinfomapsmall";var v=null;if(identifiertype==4){v="npcpositions"}if(identifiertype==6){v="objectpositions"}if(identifiertype==1){v="fishingpositions"}if(identifiertype==5){v="questeventpositions"+z}var t="action="+v+"&id="+identifier+"&zoneid="+C[f][0]+"&level="+C[f][2]+"&mode=zone";if(!browserIsIE){h.innerHTML='<embed src="mapviewer/SDMapViewer.swf" FlashVars="'+t+'" quality="high" bgcolor="#000000" width="'+B+'" height="'+o+'" wmode="opaque" name="SDMapViewer" id="SDMapViewer" align="middle" play="true" loop="false" quality="high" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.adobe.com/go/getflashplayer"></embed>'}else{if(browserIsIE){h.innerHTML='<object type="application/x-shockwave-flash" id="SDMapViewer" width="'+B+'" height="'+o+'" data="mapviewer/SDMapViewer.swf"><param name="movie" value="mapviewer/SDMapViewer.swf" /><param name="quality" value="high" /><param name="bgcolor" value="#000000" /><param name="allowScriptAccess" value="sameDomain" /><param name="wmode" value="opaque"><param name="FlashVars" value="'+t+'"></object>'}else{h.innerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" id="SDMapViewer" width="'+B+'" height="'+o+'"><param name="movie" value="mapviewer/SDMapViewer.swf" /><param name="quality" value="high" /><param name="bgcolor" value="#000000" /><param name="allowScriptAccess" value="sameDomain" /><param name="wmode" value="opaque"><param name="FlashVars" value="'+t+'"></object>'}}if(browserIsNetscape){h.addEventListener("DOMMouseScroll",flashMapWheel,false)}h.onmousewheel=flashMapWheel;d.appendChild(h)}else{var n=document.createElement("div");n.id="extinfodetailscontainer"+u+"map";n.className=(windowAtFullSize()==true)?"extinfomap":"extinfomapsmall";var a=C[f][2];n.style.backgroundImage="url('images/wowmaps/"+(windowAtFullSize()?"":"small")+"/"+C[f][0]+(a>0?"_"+a:"")+".jpg')";var w;for(w=0;w<C[f][4].length;w++){var p=C[f][4][w][0];var s=C[f][4][w][1];var g=C[f][4][w][2];var c=(Math.round(g/10)*5)+50;if(c<=0){c=10}if(c>100){c=100}if(p>100){p=100}if(p<0){p=0}if(s>100){s=100}if(s<0){s=0}var e=(B/101)*p;var j=(o/101)*s;var m=document.createElement("div");m.className="extinfomappoint";m.style.position="absolute";m.style.left=e+"px";m.style.top=j+"px";if(C[f][3].length<5){c="100white"}m.style.backgroundImage="url('images/mapalpha/"+c+".png')";m.onmouseover=new Function("displayExtInfoMapCoords("+u+","+p+","+s+");");m.onmouseout=new Function("clearExtInfoMapCoords("+u+");");n.appendChild(m)}d.appendChild(n)}A.appendChild(d);b.appendChild(A);y.appendChild(b);r.appendChild(y)}function closeExtInfoMap(b){var a=document.getElementById("extinfodetailscontainer"+b);removeAllChilds(a)}function displayExtInfoMapCoords(c,b,a){clearExtInfoMapCoords(c);var d=document.createElement("div");d.id="extinfodetailscontainer"+c+"mapcoords";d.className="extinfomapcoords";d.appendChild(document.createTextNode(b+" / "+a));document.getElementById("extinfodetailscontainer"+c+"map").appendChild(d)}function clearExtInfoMapCoords(a){var b=document.getElementById("extinfodetailscontainer"+a+"mapcoords");if(b!=null){document.getElementById("extinfodetailscontainer"+a+"map").removeChild(b)}}function toggleFlashMap(c,a,b){if(c){setPermanentCookie("noFlashMap","false")}else{setPermanentCookie("noFlashMap","true")}displayExtInfoMap(a,b,((extinfodata[a][3][b][3]==true)?true:false))}function flashMapWheelHandle(c){var a;if(browserIsIE){a=window.SDMapViewer}else{a=document.getElementById("SDMapViewer")}if(a){try{a.externalZoom(c>0?-1:1)}catch(b){}}}function flashMapWheel(a){var b=0;if(!a){a=window.event}if(a.wheelDelta){b=-a.wheelDelta/120}else{if(a.detail){b=a.detail}}if(a.preventDefault){a.preventDefault()}a.returnValue=false;if(b){flashMapWheelHandle(b)}}var commentdata=null;function postAJAXCommentRequest(c,a){displayLoadingScreen();var b="comment?id="+c+"&type="+a;startAJAXRequest(b,processAJAXCommentResponse)}function processAJAXCommentResponse(e){var d=e.split("|");var c,b;var g;commentdata=new Array();for(c=0;c<d.length;c++){var f=new Array();if(d[c]!=""){var a=d[c].split("#");if(a.length==6){f.push(parseInt(a[0]));f.push(a[1]);f.push(parseInt(a[2]));f.push(parseInt(a[3]));f.push(parseInt(a[4]));f.push(decodeText(a[5]));commentdata.push(f)}}}displayTab(commenttabid,0,0,0)}function displayComments(r){var h=document.createElement("table");h.id="listcontent";h.width="100%";h.border=0;h.cellPadding=4;h.cellSpacing=0;var u=document.createElement("tbody");var o;var f=commentdata.length;if(loggedinas!=null){f++}for(o=0;o<f;o++){var j=document.createElement("tr");var d=document.createElement("td");var b=document.createElement("table");var p=document.createElement("tbody");b.width="100%";b.border=0;b.cellPadding=4;b.cellSpacing=0;b.className="commentOuter";var t=document.createElement("tr");listcontent_tr_td_table_tr_td=document.createElement("td");listcontent_tr_td_table_tr_td.className="commentTitle";var n=document.createElement("table");var c=document.createElement("tbody");n.width="100%";n.border=0;n.cellPadding=0;n.cellSpacing=0;listcontent_tr_td_table_tr_td_table_tr=document.createElement("tr");listcontent_tr_td_table_tr_td_table_tr_td=document.createElement("td");listcontent_tr_td_table_tr_td_table_tr_td.width="50%";var g=document.createElement("strong");if(o<commentdata.length){var m="#"+(o+1);var e=" - "+commentdata[o][1];var q=new Date(commentdata[o][3]*1000);var s=formatDate(q);g.appendChild(document.createTextNode(m));listcontent_tr_td_table_tr_td_table_tr_td.appendChild(g);listcontent_tr_td_table_tr_td_table_tr_td.appendChild(document.createTextNode(e+" "));listcontent_tr_td_table_tr_td_table_tr_td_span=document.createElement("span");listcontent_tr_td_table_tr_td_table_tr_td_span.className="lilbitsmallertext";listcontent_tr_td_table_tr_td_table_tr_td_span.appendChild(document.createTextNode("("+s+" Uhr)"));listcontent_tr_td_table_tr_td_table_tr_td.appendChild(listcontent_tr_td_table_tr_td_table_tr_td_span);listcontent_tr_td_table_tr_td_table_tr.appendChild(listcontent_tr_td_table_tr_td_table_tr_td);listcontent_tr_td_table_tr_td_table_tr_td2=document.createElement("td");listcontent_tr_td_table_tr_td_table_tr_td2.width="50%";listcontent_tr_td_table_tr_td_table_tr_td2.align="right";listcontent_tr_td_table_tr_td_table_tr_td2.className="lilbitsmallertext";if(commentdata[o][1]==loggedinas||accountlevel>=2){listcontent_tr_td_table_tr_td_table_tr_td2.appendChild(document.createTextNode("Aktionen: "));listcontent_tr_td_table_tr_td_table_tr_td2_a=document.createElement("a");listcontent_tr_td_table_tr_td_table_tr_td2_a.href="javascript:deleteComment("+commentdata[o][0]+")";listcontent_tr_td_table_tr_td_table_tr_td2_a.appendChild(document.createTextNode("löschen"));listcontent_tr_td_table_tr_td_table_tr_td2.appendChild(listcontent_tr_td_table_tr_td_table_tr_td2_a);listcontent_tr_td_table_tr_td_table_tr_td2.appendChild(document.createTextNode(" | "))}listcontent_tr_td_table_tr_td_table_tr_td2.appendChild(document.createTextNode("Bewertung: "));listcontent_tr_td_table_tr_td_table_tr_td2_span=document.createElement("span");if(commentdata[o][4]>0){listcontent_tr_td_table_tr_td_table_tr_td2_span.className="positiverating";listcontent_tr_td_table_tr_td_table_tr_td2_span.appendChild(document.createTextNode("+"+commentdata[o][4]))}if(commentdata[o][4]<0){listcontent_tr_td_table_tr_td_table_tr_td2_span.className="negativerating";listcontent_tr_td_table_tr_td_table_tr_td2_span.appendChild(document.createTextNode(commentdata[o][4]))}if(commentdata[o][4]==0){listcontent_tr_td_table_tr_td_table_tr_td2_span.className="neutralrating";listcontent_tr_td_table_tr_td_table_tr_td2_span.appendChild(document.createTextNode(commentdata[o][4]))}listcontent_tr_td_table_tr_td_table_tr_td2.appendChild(listcontent_tr_td_table_tr_td_table_tr_td2_span);listcontent_tr_td_table_tr_td_table_tr_td2.appendChild(document.createTextNode(" "));listcontent_tr_td_table_tr_td_table_tr_td2_a=document.createElement("a");listcontent_tr_td_table_tr_td_table_tr_td2_a.href="javascript:rateComment("+commentdata[o][0]+",'positive')";listcontent_tr_td_table_tr_td_table_tr_td2_a.appendChild(document.createTextNode("[+]"));listcontent_tr_td_table_tr_td_table_tr_td2.appendChild(listcontent_tr_td_table_tr_td_table_tr_td2_a);listcontent_tr_td_table_tr_td_table_tr_td2.appendChild(document.createTextNode(" "));listcontent_tr_td_table_tr_td_table_tr_td2_a2=document.createElement("a");listcontent_tr_td_table_tr_td_table_tr_td2_a2.href="javascript:rateComment("+commentdata[o][0]+",'negative')";listcontent_tr_td_table_tr_td_table_tr_td2_a2.appendChild(document.createTextNode("[-]"));listcontent_tr_td_table_tr_td_table_tr_td2.appendChild(listcontent_tr_td_table_tr_td_table_tr_td2_a2);listcontent_tr_td_table_tr_td_table_tr.appendChild(listcontent_tr_td_table_tr_td_table_tr_td2)}else{g.appendChild(document.createTextNode("Neuen Kommentar schreiben"));listcontent_tr_td_table_tr_td_table_tr_td.appendChild(g);listcontent_tr_td_table_tr_td_table_tr.appendChild(listcontent_tr_td_table_tr_td_table_tr_td)}c.appendChild(listcontent_tr_td_table_tr_td_table_tr);n.appendChild(c);listcontent_tr_td_table_tr_td.appendChild(n);t.appendChild(listcontent_tr_td_table_tr_td);p.appendChild(t);b.appendChild(p);listcontent_tr_td_table_tr2=document.createElement("tr");listcontent_tr_td_table_tr2_td=document.createElement("td");if(o<commentdata.length){if(commentdata[o][4]>=25&&commentdata[o][2]<2){listcontent_tr_td_table_tr2_td.className="commentcolorpositive"}else{if(commentdata[o][4]<0&&commentdata[o][2]<2){listcontent_tr_td_table_tr2_td.className="commentcolornegative"}else{listcontent_tr_td_table_tr2_td.className="commentcolor"+commentdata[o][2]}}var a=commentdata[o][5].split("\n");var l;for(l=0;l<a.length;l++){listcontent_tr_td_table_tr2_td.appendChild(document.createTextNode(a[l]));if(l+1<a.length){listcontent_tr_td_table_tr2_td.appendChild(document.createElement("br"))}}}else{listcontent_tr_td_table_tr2_td_textarea=document.createElement("textarea");listcontent_tr_td_table_tr2_td_textarea.cols=80;listcontent_tr_td_table_tr2_td_textarea.rows=6;listcontent_tr_td_table_tr2_td_textarea.name="mycomment";listcontent_tr_td_table_tr2_td_textarea.id="mycomment";listcontent_tr_td_table_tr2_td.appendChild(listcontent_tr_td_table_tr2_td_textarea);listcontent_tr_td_table_tr2_td_input=document.createElement("input");listcontent_tr_td_table_tr2_td_input.type="button";listcontent_tr_td_table_tr2_td_input.name="sendcomment";listcontent_tr_td_table_tr2_td_input.id="sendcomment";listcontent_tr_td_table_tr2_td_input.value="Abschicken";listcontent_tr_td_table_tr2_td_input.onclick=sendComment;listcontent_tr_td_table_tr2_td.appendChild(listcontent_tr_td_table_tr2_td_input)}listcontent_tr_td_table_tr2.appendChild(listcontent_tr_td_table_tr2_td);p.appendChild(listcontent_tr_td_table_tr2);b.appendChild(p);d.appendChild(b);j.appendChild(d);u.appendChild(j);h.appendChild(u)}r.appendChild(h)}function sendComment(){var a=document.getElementById("mycomment");var d=a.value;var b=new Array();b.push("id");b.push(identifier);b.push("type");b.push(identifiertype);b.push("text");b.push(encodeURIComponent(d));var c=document.getElementById("sendcomment");c.disabled=true;startAJAXPostRequest("comment",b,processAJAXSendCommentResponse)}function processAJAXSendCommentResponse(a){var b=document.getElementById("sendcomment");b.disabled=false;if(a=="success"){commentdata=null;displayTab(commenttabid,0,0,0)}else{alert("Beim Speichern des Kommentars trat ein Fehler auf: "+a)}}function rateComment(a,b){b=(b=="positive")?1:0;var c="comment?command=rate&commentid="+a+"&positive="+b;startAJAXRequest(c,processAJAXCommentRatingResponse)}function deleteComment(a){var b="comment?command=delete&commentid="+a;startAJAXRequest(b,processAJAXCommentRatingResponse)}function processAJAXCommentRatingResponse(a){alert(a);commentdata=null;displayTab(commenttabid,0,0,0)}var screenshotdata=null;function postAJAXScreenshotRequest(c,a){displayLoadingScreen();var b="screenshot?id="+c+"&type="+a;startAJAXRequest(b,processAJAXScreenshotResponse)}function processAJAXScreenshotResponse(f){var e=f.split("|");var c,b;var g;screenshotdata=new Array();for(c=0;c<e.length;c++){var d=new Array();if(e[c]!=""){var a=e[c].split("#");if(a.length==9){d.push(parseInt(a[0]));d.push(decodeText(a[1]));d.push(a[2]);d.push(a[3]);d.push(parseInt(a[4]));d.push(parseInt(a[5]));d.push(parseInt(a[6]));d.push(parseInt(a[7]));d.push(parseInt(a[8]));screenshotdata.push(d)}}}displayTab(screenshottabid,0,0,0)}function displayScreenshots(d){var m=(windowAtHalfSize()==true)?3:2;var e=document.createElement("table");e.id="listcontent";e.width="100%";e.border=0;e.cellPadding=4;e.cellSpacing=0;var q,b;var h=0;var r=Math.ceil(screenshotdata.length/m);var f=document.createElement("tbody");for(q=0;q<r;q++){f=document.createElement("tbody");var c=document.createElement("tr");for(b=0;b<m;b++){var a=document.createElement("td");a.width="33%";if(h<screenshotdata.length){var j=screenshotdata[h];var l=document.createElement("table");l.width=330;l.border=0;l.cellPadding=4;l.cellSpacing=0;l.align="center";var p=document.createElement("tbody");var o=document.createElement("tr");listcontent_tr_td_table_tr_td=document.createElement("td");listcontent_tr_td_table_tr_td.align="center";listcontent_tr_td_table_tr_td_a=document.createElement("a");listcontent_tr_td_table_tr_td_a.href="javascript:fullsizeScreenshot("+j[0]+","+j[7]+","+j[8]+")";listcontent_tr_td_table_tr_td_a_img=document.createElement("img");listcontent_tr_td_table_tr_td_a_img.className="screenshot";listcontent_tr_td_table_tr_td_a_img.src="screenshots/thumbs/"+j[2];listcontent_tr_td_table_tr_td_a_img.width=j[5];listcontent_tr_td_table_tr_td_a_img.height=j[6];listcontent_tr_td_table_tr_td_a.appendChild(listcontent_tr_td_table_tr_td_a_img);listcontent_tr_td_table_tr_td.appendChild(listcontent_tr_td_table_tr_td_a);o.appendChild(listcontent_tr_td_table_tr_td);p.appendChild(o);listcontent_tr_td_table_tr2=document.createElement("tr");listcontent_tr_td_table_tr2_td=document.createElement("td");listcontent_tr_td_table_tr2_td.align="center";listcontent_tr_td_table_tr2_td.appendChild(document.createTextNode(j[1]));listcontent_tr_td_table_tr2.appendChild(listcontent_tr_td_table_tr2_td);p.appendChild(listcontent_tr_td_table_tr2);listcontent_tr_td_table_tr3=document.createElement("tr");listcontent_tr_td_table_tr3_td=document.createElement("td");listcontent_tr_td_table_tr3_td.align="center";listcontent_tr_td_table_tr3_td.className="lilbitsmallertext";listcontent_tr_td_table_tr3_td.appendChild(document.createTextNode("von "+j[3]+" ("+formatDate(new Date(j[4]*1000))+" Uhr)"));listcontent_tr_td_table_tr3.appendChild(listcontent_tr_td_table_tr3_td);p.appendChild(listcontent_tr_td_table_tr3);l.appendChild(p);a.appendChild(l)}c.appendChild(a);h++}f.appendChild(c);e.appendChild(f)}if(loggedinas!=null){var g=document.createElement("tr");listcontent_tr2_td2=document.createElement("td");listcontent_tr2_td2.colSpan=m;listcontent_tr2_td2.align="center";var n=document.createElement("iframe");n.width=630;n.height=190;n.frameBorder=0;n.border=0;n.id="uploadframe";n.src="screenshot?id="+identifier+"&type="+identifiertype+"&action=upload";listcontent_tr2_td2.appendChild(n);g.appendChild(listcontent_tr2_td2);f.appendChild(g);e.appendChild(f)}d.appendChild(e)}function finishScreenshotUpload(){screenshotdata=null;displayTab(screenshottabid,0,0,0)}function fullsizeScreenshot(c,b,a){window.open("screenshot?id="+c+"&action=fullsize","screenshotwindow","width="+b+", height="+a+", directories=no, toolbar=no, location=no, menubar=no, scrollbars=no, status=no, resizable=yes, dependent=no")}var linktitles=["BLASC","GetWoW","WoW-Handwerk","Wowhead","Wowhead","Allakhazam","Thottbot"];var linkhostnames=["http://www.buffed.de","http://wowdatabase.gamona.de","http://wowhandwerk.onlinewelten.com","http://de.wowhead.com","http://www.wowhead.com","http://wow.allakhazam.com/db","http://www.thottbot.com"];var linkprefix=[null,["/?i=","/item/","/item.php?id=","?item=","?item=","/item.html?witem=","/i"],[null,null,null,"?spell=","?spell=","/spell.html?wspell=","/s"],["/blasc/53/set?set_id=","/item/sets/classic/","/set.php?id=","/?itemset=","/?itemset=","/itemset.html?setid=","/?set="],["/?n=","/creature/","/npc.php?id=","/?npc=","/?npc=","/mob.html?wmob=","/c"],["/?q=","/quest/","/quest.php?id=","/?quest=","/?quest=","/quest.html?wquest=","/q"],null,null,["/blasc/90/von-fraktionen?f_id=","/faction/",null,"/?faction=","/?faction=","/faction.html?wfaction=","/f"],[null,null,null,"?achievement=","?achievement=",null,"/ach"]];var linkpostfix=[null,["","-/","","","","",""],[null,null,null,"","","",""],["","-/","","","","",""],["","-/","","","","",""],["","-/","","","","",""],null,null,["","-/",null,"","","",""],["","-/",null,"","","",""]];function toggleDatabaseLinks(c,l){var a=document.getElementById("linksbutton");var h=document.getElementById("linksdiv");if(h!=null){a.removeChild(h);return}h=document.createElement("div");h.id="linksdiv";var g,f;for(f=0;f<2;f++){if(linkprefix[l][f*4+0]!=null||linkprefix[l][f*4+1]!=null||linkprefix[l][f*4+2]!=null||linkprefix[l][f*4+3]!=null){var e=document.createElement("b");e.appendChild(document.createTextNode((f==0)?"deutschsprachig":"englischsprachig"));h.appendChild(e);var j=document.createElement("ul");for(g=f*4;g<f*4+4;g++){if(linkprefix[l][g]!=null){var b=document.createElement("li");var d=document.createElement("a");d.href=linkhostnames[g]+linkprefix[l][g]+c+linkpostfix[l][g];d.target="blank";d.appendChild(document.createTextNode(linktitles[g]));b.appendChild(d);j.appendChild(b)}}h.appendChild(j);if(f==0){h.appendChild(document.createElement("br"))}}}a.appendChild(h)}function renderItemStackSize(e){if(e==1){return}var b=document.getElementById("itemicon").firstChild;var d=document.createElement("div");d.className="count";var f=document.createElement("div");f.appendChild(document.createTextNode(e));f.className="text";d.appendChild(f);var c;for(c=1;c<=8;c++){var a=document.createElement("div");a.className="textborder"+c;a.appendChild(document.createTextNode(e));d.appendChild(a)}b.appendChild(d)}function toggleArmoryStats(){var a=document.getElementById("armoryitemstats");if(a.style.display=="block"){a.style.display="none"}else{a.style.display="block"}}function showScalingItem(a){window.location.href="item?id="+identifier+"."+a+(window.location.href.charAt(window.location.href.length-1)=="b"?"b":"")}function updateSpellFilterVisibility(){if((currentcategory>=278&&currentcategory<294)||(currentcategory>=300&&currentcategory<=312)){document.getElementById("skilllevelfilter").style.display="";document.getElementById("mechanicfilter").style.display="none";document.getElementById("dispeltypefilter").style.display="none";document.getElementById("spellschoolfilter").style.display="none";document.getElementById("itemslotfilter").style.display=""}else{document.getElementById("skilllevelfilter").style.display="none";document.getElementById("mechanicfilter").style.display="";document.getElementById("dispeltypefilter").style.display="";document.getElementById("spellschoolfilter").style.display="";document.getElementById("itemslotfilter").style.display="none"}}function showScalingSpell(a){window.location.href="spell?id="+identifier+"."+a+(window.location.href.charAt(window.location.href.length-1)=="b"?"b":"")}function setupZoneMap(f){var l=f;if(f==true){if(getCookie("noZoneFlashMap")=="true"){f=false}}var d=document.getElementById("zonemapcontainer");var e=document.getElementById("normalmapoptions");if(f){var c=document.getElementById("zonemap");c.style.display="none";var o=document.getElementById("flashzonemap");if(o==null){var h="zonepositions";var m="?action="+h+"&id="+identifier+"&zoneid="+identifier;var g=750;var b=500;o=document.createElement("div");o.id="flashzonemap";if(browserIsNetscape){o.innerHTML='<embed src="mapviewer/SDMapViewer.swf'+m+'" quality="high" bgcolor="#DFDFDF" width="'+g+'" height="'+b+'" wmode="opaque" name="SDMapViewer" id="SDMapViewer" align="middle" play="true" loop="false" quality="high" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.adobe.com/go/getflashplayer"></embed>'}else{if(browserIsIE){o.innerHTML='<object type="application/x-shockwave-flash" id="SDMapViewer" width="'+g+'" height="'+b+'" data="mapviewer/SDMapViewer.swf'+m+'"><param name="movie" value="mapviewer/SDMapViewer.swf'+m+'" /><param name="quality" value="high" /><param name="bgcolor" value="#DFDFDF" /><param name="allowScriptAccess" value="sameDomain" /><param name="wmode" value="opaque"></object>'}else{o.innerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" id="SDMapViewer" width="'+g+'" height="'+b+'"><param name="movie" value="mapviewer/SDMapViewer.swf'+m+'" /><param name="quality" value="high" /><param name="bgcolor" value="#DFDFDF" /><param name="allowScriptAccess" value="sameDomain" /><param name="wmode" value="opaque"></object>'}}d.appendChild(o);if(browserIsNetscape){o.addEventListener("DOMMouseScroll",flashMapWheel,false)}o.onmousewheel=flashMapWheel}e.style.display="none"}else{var c=document.getElementById("flashzonemap");if(c!=null){d.removeChild(c)}c=document.getElementById("zonemap");c.style.display="block";e.style.display="inline";setupZoneMapDisplay()}var j=document.getElementById("flashmaptoggle");removeAllChilds(j);if(l){var n=document.createElement("a");if(!f){n.href="javascript:toggleFlashZoneMap(true);";n.appendChild(document.createTextNode("nutze erweiterte, Flash-basierte Karte"))}else{n.href="javascript:toggleFlashZoneMap(false);";n.appendChild(document.createTextNode("nutze einfache Karte ohne Flash"))}j.appendChild(n)}else{j.appendChild(document.createTextNode("keine Flash-basierte Karte für diese Zone verfügbar"))}}function setupZoneMapDisplay(){if(maplevelcount>0&&document.getElementById("maplevel")==null){var c=document.getElementById("normalmapoptions");var f=document.createElement("select");f.id="maplevel";f.onclick=updateZoneMapDisplay;f.style.marginRight="10px";var d;for(d=mapbaselevel;d<=maplevelcount;d++){var e=document.createElement("option");e.value=d;e.appendChild(document.createTextNode(d));if(d==mapbaselevel){e.defaultSelected=true;e.selected=true}f.appendChild(e)}var a=document.createElement("b");a.appendChild(document.createTextNode("Areal: "));c.insertBefore(f,c.firstChild);c.insertBefore(a,f)}updateZoneMapDisplay()}function updateZoneMapDisplay(){var a="";var b=document.getElementById("maplevel");if(b!=null&&b.value>0){a="_"+b.value}var c=document.getElementById("zonemap");c.style.backgroundImage="url('images/wowmaps/"+mapbaseid+a+".jpg')";clearZoneMap()}function getZoneMapLevel(){var a=document.getElementById("maplevel");if(a!=null){return a.value}else{return 0}}function clearZoneMap(){var a=document.getElementById("zonemap");removeAllChilds(a)}function displayZoneQuestGivers(){clearZoneMap();var d=document.getElementById("zonemap");var g;var b=getZoneMapLevel();for(g=0;g<zonequestgivers[b].length;g++){var l=zonequestgivers[b][g];var f=l[0];var h=l[1];var j="zm"+f+"."+h;var c=document.getElementById("dot");if(c==null){c=document.createElement("div");c.className="zonemapdot";c.id=j;var a=(750/101)*f;var e=(500/101)*h;c.style.left=a+"px";c.style.top=e+"px";c.style.zIndex=10;c.onmouseover=new Function("showZoneMapTooltip("+f+","+h+",'quest');");c.onmouseout=leaveZoneMapDot;d.appendChild(c)}}}function displayZoneMerchants(){clearZoneMap();var d=document.getElementById("zonemap");var g;var b=getZoneMapLevel();for(g=0;g<zonemerchants[b].length;g++){var l=zonemerchants[b][g];var f=l[0];var h=l[1];var j="zm"+f+"."+h;var c=document.getElementById("dot");if(c==null){c=document.createElement("div");c.className="zonemapdot";c.id=j;var a=(750/101)*f;var e=(500/101)*h;c.style.left=a+"px";c.style.top=e+"px";c.style.zIndex=10;c.onmouseover=new Function("showZoneMapTooltip("+f+","+h+",'merchant');");c.onmouseout=leaveZoneMapDot;d.appendChild(c)}}}function showZoneMapTooltip(l,m,c){var t,q;var a=getZoneMapLevel();var d=document.getElementById("zonemaptooltip");if(d!=null){hideZoneMapTooltip()}d=document.createElement("div");d.id="zonemaptooltip";d.onmouseover=new Function("event","enterZoneMapTooltip(); event.cancelBubble=true; if(event.stopPropagation) event.stopPropagation();");d.onmouseout=new Function("event","hideZoneMapTooltip(event);");var r=document.createElement("span");r.className="lilbitsmallertext";r.appendChild(document.createTextNode("an Position "+l+" / "+m));d.appendChild(r);d.appendChild(document.createElement("br"));var p=document.createElement("div");p.style.textAlign="left";p.style.marginTop="6px";var j=true;if(c=="quest"){for(t=0;t<zonequestgivers[a].length;t++){var b=zonequestgivers[a][t];if(b[0]==l&&b[1]==m){if(!j){p.appendChild(document.createElement("br"))}j=false;var s=document.createElement("a");s.className="zonemapquestsource";s.href=b[3]+"?id="+b[4];s.appendChild(document.createTextNode(b[2]));p.appendChild(s);for(q=0;q<b[5].length;q++){var h=b[5][q];var o=document.createElement("div");o.className="zonemapquest";o.appendChild(document.createTextNode("["+h[2]+"] "));var e=document.createElement("a");e.href="quest?id="+h[0];e.appendChild(document.createTextNode(h[1]));o.appendChild(e);p.appendChild(o)}}}}if(c=="merchant"){for(t=0;t<zonemerchants[a].length;t++){var b=zonemerchants[a][t];if(b[0]==l&&b[1]==m){for(q=0;q<b[2].length;q++){var f=b[2][q];if(!j){p.appendChild(document.createElement("br"))}j=false;var s=document.createElement("a");s.href="npc?id="+f[0];s.appendChild(document.createTextNode(f[1]));p.appendChild(s);var g=document.createElement("div");g.className="lilbitsmallertext";g.appendChild(document.createTextNode(f[2]));p.appendChild(g)}}}}d.appendChild(p);var n=document.getElementById("zm"+l+"."+m);n.style.zIndex=20;n.appendChild(d)}function hideZoneMapTooltip(a){var b=document.getElementById("zonemaptooltip");if(b==null){return}if(a!=null){var c=a.relatedTarget||a.toElement;if(c==b||isNodeChildOf(c,b)){return}}b.parentNode.style.zIndex=10;b.parentNode.removeChild(b)}function autoHideZoneMapTooltip(b){var a=document.getElementById("zonemaptooltip");if(a==null){return}if(a.hasEntered!=true&&a.hideConfirmation==b){hideZoneMapTooltip()}}function enterZoneMapTooltip(){var a=document.getElementById("zonemaptooltip");if(a==null){return}a.hasEntered=true}function leaveZoneMapDot(){var a=document.getElementById("zonemaptooltip");if(a==null){return}a.hideConfirmation=Math.floor(Math.random()*10000);window.setTimeout("autoHideZoneMapTooltip("+a.hideConfirmation+")",500)}function isNodeChildOf(b,a){if(b==null){return false}if(b.parentNode==a){return true}else{if(b.parentNode!=null){return isNodeChildOf(b.parentNode,a)}else{return false}}}function toggleFlashZoneMap(a){if(a){setPermanentCookie("noZoneFlashMap","false")}else{setPermanentCookie("noZoneFlashMap","true")}setupZoneMap(true)}function flashMapWheelHandle(c){var a;if(browserIsIE){a=window.SDMapViewer}else{a=document.getElementById("SDMapViewer")}if(a){try{a.externalZoom(c>0?-1:1)}catch(b){}}}function flashMapWheel(a){var b=0;if(!a){a=window.event}if(a.wheelDelta){b=-a.wheelDelta/120}else{if(a.detail){b=a.detail}}if(a.preventDefault){a.preventDefault()}a.returnValue=false;if(b){flashMapWheelHandle(b)}}function displayModelViewer(e,d,h,c){if(d==1||d==3){c.appendChild(getModelViewerApplet(e,h,0,false))}else{var f=getCookie("omv_charid");var b=(getCookie("omv_saveselection")=="true")?true:false;var g=(getCookie("omv_fullanimations")=="true")?true:false;var a=(getCookie("omv_largesize")=="true")?true:false;if(f!=null){c.appendChild(getModelViewerApplet(e,h,f,g?false:true,a))}else{displayModelRaceSelection(e,h,g,b,a,c)}}scrollToBottom()}function displayBakedModel(l,a,j){var h=false;var d=false;var e=false;var n=document.getElementById("saveselection");if(n){d=n.checked}var f=document.getElementById("fullanimations");if(f){h=f.checked}var g=document.getElementById("largesize");if(g){e=g.checked}var m=j+1000000;if(d){setPermanentCookie("omv_charid",m);setPermanentCookie("omv_fullanimations",h?"true":"false");setPermanentCookie("omv_saveselection",d?"true":"false");setPermanentCookie("omv_largesize",e?"true":"false")}else{deleteCookie("omv_saveselection");deleteCookie("omv_fullanimations");deleteCookie("omv_largesize")}var b=document.getElementById("listbody");var c=document.getElementById("listcontent");b.replaceChild(getModelViewerApplet(l,a,m,h?false:true,e),c)}function changeModelRaceSelection(){deleteCookie("omv_charid");displayTab(selectedTab,-1,-1,0)}function displayModelRaceSelection(h,t,s,v,w,A){var x=getTable("100%",0,0,0);x.id="listcontent";x.style.height="500px";var E=document.createElement("tbody");var y=document.createElement("tr");var n=document.createElement("td");n.align="center";n.vAlign="middle";var b=document.createElement("p");var o=[1,3,4,7,11,2,5,6,8,10];var j=["Menschen","Zwerge","Nachtelfen","Gnome","Draenei","Orks","Untote","Tauren","Trolle","Blutelfen"];var f,a,p;b.appendChild(document.createTextNode(((h=="itemset")?"Dieses Set":"Dieser Gegenstand")+" kann nur an einem Charakter gezeigt werden. Bitte wähle die gewünschte Rasse:"));n.appendChild(b);n.appendChild(document.createElement("br"));for(f=0;f<2;f++){var e=getTable(700,0,0,0);var B=document.createElement("tbody");var d=document.createElement("tr");var D=document.createElement("tr");for(a=f*5;a<5+f*5;a++){var c=o[a];var C=o[a]*10;l=document.createElement("td");var u=document.createElement("table");u.width=140;u.border=0;u.cellSpacing=4;u.cellPadding=0;inner_table_tbody=document.createElement("tbody");inner_table_tr=document.createElement("tr");for(p=0;p<2;p++){var r=document.createElement("td");var z=document.createElement("a");z.href='javascript:displayBakedModel("'+h+'",'+t+","+(C+p)+")";var g=document.createElement("img");g.border=0;g.src="images/races/race"+c+(p==0?"m":"f")+".png";z.appendChild(g);r.appendChild(z);inner_table_tr.appendChild(r)}inner_table_tbody.appendChild(inner_table_tr);u.appendChild(inner_table_tbody);l.appendChild(u);d.appendChild(l);var m=document.createElement("td");m.align="center";m.style.fontWeight="bold";m.appendChild(document.createTextNode(j[a]));D.appendChild(m)}B.appendChild(d);B.appendChild(D);e.appendChild(B);n.appendChild(e);if(f==0){n.appendChild(document.createElement("br"));n.appendChild(document.createElement("br"))}}n.appendChild(document.createElement("br"));n.appendChild(document.createElement("br"));var e=getTable(350,0,4,0);var B=document.createElement("tbody");var d=document.createElement("tr");var l=document.createElement("td");l.width=20;var q=getCheckbox("saveselection","true",v,v,null);l.appendChild(q);d.appendChild(l);l=document.createElement("td");l.align="left";l.appendChild(document.createTextNode("Auswahl auf diesem Rechner speichern"));d.appendChild(l);B.appendChild(d);d=document.createElement("tr");l=document.createElement("td");l.width=20;q=getCheckbox("fullanimations","true",s,s,null);l.appendChild(q);d.appendChild(l);l=document.createElement("td");l.align="left";l.appendChild(document.createTextNode("Lade Modelle mit vollständigen Animationen"));d.appendChild(l);B.appendChild(d);d=document.createElement("tr");l=document.createElement("td");l.width=20;q=getCheckbox("largesize","true",w,w,null);l.appendChild(q);d.appendChild(l);l=document.createElement("td");l.align="left";l.appendChild(document.createTextNode("Extragroßes Modelviewer-Fenster"));d.appendChild(l);B.appendChild(d);e.appendChild(B);n.appendChild(e);y.appendChild(n);E.appendChild(y);x.appendChild(E);A.appendChild(x)}function getModelViewerApplet(p,e,r,o,s){var l="015";var q="003";var h=document.createElement("table");h.id="listcontent";h.width="100%";h.border=0;h.cellPadding=4;h.cellSpacing=0;var j=document.createElement("tbody");var g=document.createElement("tr");var c=document.createElement("td");c.align="center";var b=getWindowWidth()-(40+30);if(b>1190){b=1190}var a=s==true?750:500;if(browserIsOpera){c.innerHTML='<applet code="firehead.omv.applet.OnlineModelViewer.class" archive="modelviewer/omv_'+l+".jar,modelviewer/jpct_"+q+'.jar" width="'+b+'" height="'+a+'" align="center" ><param name="bgcolor" value="000000"><param name="type" value="'+p+'"><param name="id" value="'+e+'"><param name="charid" value="'+r+'"><param name="stripped" value="'+(o?"true":"false")+'"></applet>'}else{var d=document.createElement("applet");d.archive="modelviewer/omv_"+l+".jar,modelviewer/jpct.jar";d.code="firehead.omv.applet.OnlineModelViewer.class";d.width=b;d.height=a;d.appendChild(getAppletParam("bgcolor","000000"));d.appendChild(getAppletParam("type",p));d.appendChild(getAppletParam("id",e));d.appendChild(getAppletParam("charid",r));d.appendChild(getAppletParam("stripped",o?"true":"false"));c.appendChild(d)}g.appendChild(c);j.appendChild(g);h.appendChild(j);if(r!=0){var m=document.getElementById("listheader");removeAllChilds(m.firstChild.firstChild);var n=document.createElement("a");n.href="javascript:changeModelRaceSelection()";n.appendChild(document.createTextNode("Charakterauswahl ändern"));m.firstChild.firstChild.appendChild(n);m.firstChild.firstChild.appendChild(document.createTextNode(" | "));var f=document.createElement("a");f.href="static_help_modelviewer";f.target="_blank";f.appendChild(document.createTextNode("Was ist das?"));m.firstChild.firstChild.appendChild(f)}return h}function getAppletParam(a,b){var c=document.createElement("param");c.name=a;c.value=b;return c}function showFilters(){document.getElementById("filters").className=null;document.getElementById("showfilters").className="hidden";filterListVisible=true}function hideFilters(){document.getElementById("filters").className="hidden";document.getElementById("showfilters").className=null;filterListVisible=false}var filterListVisible=false;var filterCount=0;var displayCountPerPage=50;var historyType="list";function addFilter(a,r){filterCount++;var h=document.createElement("div");h.id="filter"+filterCount;var m=document.createElement("select");m.name="filtertype"+filterCount;m.id=m.name;m.onchange=new Function("selectFilterType("+filterCount+");");var s;var f=null;var p=-1;for(s=0;s<filterTypes.length;s++){if(filterTypes[s][1]=="header"){var e=document.createElement("optgroup");e.label=filterTypes[s][0];m.appendChild(e);f=e}else{var n=document.createElement("option");n.value=s+":"+filterTypes[s][1];if(a==filterTypes[s][2]){p=s;n.defaultSelected=true;n.selected=true}n.appendChild(document.createTextNode(filterTypes[s][0]));if(f!=null){f.appendChild(n)}else{m.appendChild(n)}}}var l=document.createElement("a");l.href="javascript:removeFilter("+filterCount+");";var u=document.createElement("img");u.src="images/removefilter.gif";u.align="absmiddle";u.border=0;l.appendChild(u);h.appendChild(l);h.appendChild(document.createTextNode(" "));h.appendChild(m);var g=document.getElementById("filtercontainer");var o=document.getElementById("newfilter");g.insertBefore(h,o);if(p!=-1){selectFilterType(filterCount);if(r!=null){var j=filterTypes[p][2];var c=filterTypes[p][1];if(c=="string"){document.getElementById("filter"+j+"input_string").value=r}if(c=="bool"){var t=document.getElementById("filter"+filterCount+"input_bool");for(s=0;s<t.childNodes.length;s++){var n=t.childNodes[s];if(n.value==r){n.defaultSelected=true;n.selected=true}}}if(c=="value"){var d=r.split(";");var b=d[0];var q=d[1];var v=document.getElementById("filter"+filterCount+"input_compare");for(s=0;s<v.childNodes.length;s++){var n=v.childNodes[s];if(n.value==b){n.defaultSelected=true;n.selected=true}}document.getElementById("filter"+filterCount+"input_value").value=q}if(c=="list"){var t=document.getElementById("filter"+filterCount+"input_list");for(s=0;s<t.childNodes.length;s++){var n=t.childNodes[s];if(n.value==r){n.defaultSelected=true;n.selected=true}}}}}if(typeof setSelectedFilterPreset=="function"){setSelectedFilterPreset(null)}}function removeFilter(b){var a=document.getElementById("filter"+b);var c=document.getElementById("filtercontainer");c.removeChild(a);if(typeof setSelectedFilterPreset=="function"){setSelectedFilterPreset(null)}}function removeAllFilters(){var c=document.getElementById("filtercontainer");var b;for(b=0;b<=filterCount;b++){var a=document.getElementById("filter"+b);if(a!=null){c.removeChild(a)}}}function selectFilterType(n){clearFilterType(n);var b=document.getElementById("filter"+n);var h=document.getElementById("filtertype"+n).value;var o=h.split(":");var s=o[0];var f=o[1];var q=document.createElement("div");q.id="filtersub"+n;q.className="filtersubdiv";if(f=="string"){var e=document.createElement("input");e.id="filter"+n+"input_string";e.size=20;q.appendChild(e)}if(f=="bool"){var e=document.createElement("select");e.id="filter"+n+"input_bool";var r=document.createElement("option");r.appendChild(document.createTextNode("Ja"));r.value="1";e.appendChild(r);var p=document.createElement("option");p.appendChild(document.createTextNode("Nein"));p.value="0";e.appendChild(p);q.appendChild(e)}if(f=="value"){var e=document.createElement("select");e.id="filter"+n+"input_compare";var r=document.createElement("option");r.value="0";r.appendChild(document.createTextNode(">="));e.appendChild(r);var p=document.createElement("option");p.value="1";p.appendChild(document.createTextNode(">"));p.defaultSelected=true;e.appendChild(p);var m=document.createElement("option");m.value="2";m.appendChild(document.createTextNode("="));e.appendChild(m);var l=document.createElement("option");l.value="3";l.appendChild(document.createTextNode("<"));e.appendChild(l);var j=document.createElement("option");j.value="4";j.appendChild(document.createTextNode("<="));e.appendChild(j);q.appendChild(e);q.appendChild(document.createTextNode(" "));var d=document.createElement("input");d.id="filter"+n+"input_value";d.size=8;q.appendChild(d)}if(f=="list"){var e=document.createElement("select");e.id="filter"+n+"input_list";var g=filterTypes[s][3];var c;for(c=0;c<g.length;c+=2){var a=document.createElement("option");a.appendChild(document.createTextNode(g[c]));a.value=g[c+1];e.appendChild(a)}q.appendChild(e)}b.appendChild(q)}function clearFilterType(b){var a=document.getElementById("filter"+b);var c=document.getElementById("filtersub"+b);if(c){a.removeChild(c)}}function applyFilter(j){var z="";if(currentcategory%200!=0){z="1000#"+currentcategory+"|"}if(listType=="items"){var s=0;s=s|(((document.getElementById("q0").checked)?1:0)<<0);s=s|(((document.getElementById("q1").checked)?1:0)<<1);s=s|(((document.getElementById("q2").checked)?1:0)<<2);s=s|(((document.getElementById("q3").checked)?1:0)<<3);s=s|(((document.getElementById("q4").checked)?1:0)<<4);s=s|(((document.getElementById("q5").checked)?1:0)<<5);s=s|(((document.getElementById("q7").checked)?1:0)<<7);if(s!=0&&s!=63){z+="4#"+s+"|"}var p=0;p=p|(((document.getElementById("slot_head").checked)?1:0)<<0);p=p|(((document.getElementById("slot_neck").checked)?1:0)<<1);p=p|(((document.getElementById("slot_shoulder").checked)?1:0)<<2);p=p|(((document.getElementById("slot_back").checked)?1:0)<<3);p=p|(((document.getElementById("slot_chest").checked)?1:0)<<4);p=p|(((document.getElementById("slot_shirt").checked)?1:0)<<5);p=p|(((document.getElementById("slot_wrist").checked)?1:0)<<6);p=p|(((document.getElementById("slot_hands").checked)?1:0)<<7);p=p|(((document.getElementById("slot_waist").checked)?1:0)<<8);p=p|(((document.getElementById("slot_legs").checked)?1:0)<<9);p=p|(((document.getElementById("slot_feet").checked)?1:0)<<10);p=p|(((document.getElementById("slot_finger").checked)?1:0)<<11);p=p|(((document.getElementById("slot_trinket").checked)?1:0)<<12);p=p|(((document.getElementById("slot_tabard").checked)?1:0)<<13);p=p|(((document.getElementById("slot_mainhand").checked)?1:0)<<14);p=p|(((document.getElementById("slot_offhand").checked)?1:0)<<15);p=p|(((document.getElementById("slot_ranged").checked)?1:0)<<16);p=p|(((document.getElementById("slot_bag").checked)?1:0)<<17);p=p|(((document.getElementById("slot_none").checked)?1:0)<<18);if(p!=0&&p!=524287){z+="6#"+p+"|"}var m=0;m=m|(((document.getElementById("nobind").checked)?1:0)<<0);m=m|(((document.getElementById("boe").checked)?1:0)<<2);m=m|(((document.getElementById("bou").checked)?1:0)<<3);m=m|(((document.getElementById("bop").checked)?1:0)<<1);if(m!=0&&m!=15){z+="5#"+m+"|"}var D=Number(document.getElementById("minplevel").value);if(isNaN(D)){D=0}var f=Number(document.getElementById("maxplevel").value);if(isNaN(f)||f==0){f=255}if(D!=0||f!=255){z+="2#"+D+"-"+f+"|"}var C=Number(document.getElementById("minilevel").value);if(isNaN(C)){C=0}var g=Number(document.getElementById("maxilevel").value);if(isNaN(g)||g==0){g=255}if(C!=0||g!=255){z+="3#"+C+"-"+g+"|"}var G=document.getElementById("name").value;if(G.match("^\\s*$")){G=""}if(G!=""){z+="1#"+G+"|"}}if(listType=="spells"){var v=0;v=v|(((document.getElementById("school_physical").checked)?1:0)<<0);v=v|(((document.getElementById("school_holy").checked)?1:0)<<1);v=v|(((document.getElementById("school_fire").checked)?1:0)<<2);v=v|(((document.getElementById("school_nature").checked)?1:0)<<3);v=v|(((document.getElementById("school_frost").checked)?1:0)<<4);v=v|(((document.getElementById("school_shadow").checked)?1:0)<<5);v=v|(((document.getElementById("school_arcane").checked)?1:0)<<6);if(v!=0&&v!=127){z+="5#"+v+"|"}var A=document.getElementById("dispeltype").value;if(A!=0){z+="4#"+A+"|"}var w=document.getElementById("mechanic").value;if(w!=0){z+="3#"+w+"|"}var D=Number(document.getElementById("minplevel").value);if(isNaN(D)){D=0}var f=Number(document.getElementById("maxplevel").value);if(isNaN(f)||f==0){f=255}if(D!=0||f!=255){z+="2#"+D+"-"+f+"|"}if((currentcategory>=278&&currentcategory<294)||(currentcategory>=300&&currentcategory<=312)){var p=0;p=p|(((document.getElementById("slot_head").checked)?1:0)<<0);p=p|(((document.getElementById("slot_neck").checked)?1:0)<<1);p=p|(((document.getElementById("slot_shoulder").checked)?1:0)<<2);p=p|(((document.getElementById("slot_back").checked)?1:0)<<3);p=p|(((document.getElementById("slot_chest").checked)?1:0)<<4);p=p|(((document.getElementById("slot_shirt").checked)?1:0)<<5);p=p|(((document.getElementById("slot_wrist").checked)?1:0)<<6);p=p|(((document.getElementById("slot_hands").checked)?1:0)<<7);p=p|(((document.getElementById("slot_waist").checked)?1:0)<<8);p=p|(((document.getElementById("slot_legs").checked)?1:0)<<9);p=p|(((document.getElementById("slot_feet").checked)?1:0)<<10);p=p|(((document.getElementById("slot_finger").checked)?1:0)<<11);p=p|(((document.getElementById("slot_trinket").checked)?1:0)<<12);p=p|(((document.getElementById("slot_tabard").checked)?1:0)<<13);p=p|(((document.getElementById("slot_mainhand").checked)?1:0)<<14);p=p|(((document.getElementById("slot_offhand").checked)?1:0)<<15);p=p|(((document.getElementById("slot_ranged").checked)?1:0)<<16);p=p|(((document.getElementById("slot_bag").checked)?1:0)<<17);p=p|(((document.getElementById("slot_none").checked)?1:0)<<18);if(p!=0&&p!=524287){z+="17#"+p+"|"}var u=Number(document.getElementById("minslevel").value);if(isNaN(u)){u=0}var r=Number(document.getElementById("maxslevel").value);if(isNaN(r)||r==0){r=450}if(u!=0||r!=255){z+="18#"+u+"-"+r+"|"}}var G=document.getElementById("name").value;if(G.match("^\\s*$")){G=""}if(G!=""){z+="1#"+G+"|"}}if(listType=="itemsets"){var D=Number(document.getElementById("minplevel").value);if(isNaN(D)){D=0}var f=Number(document.getElementById("maxplevel").value);if(isNaN(f)||f==0){f=255}if(D!=0||f!=255){z+="2#"+D+"-"+f+"|"}var C=Number(document.getElementById("minilevel").value);if(isNaN(C)){C=0}var g=Number(document.getElementById("maxilevel").value);if(isNaN(g)||g==0){g=255}if(C!=0||g!=255){z+="3#"+C+"-"+g+"|"}var x=document.getElementById("class").value;if(x!=0){z+="4#"+x+"|"}var F=document.getElementById("tag").value;if(F!=0){z+="5#"+F+"|"}var G=document.getElementById("name").value;if(G.match("^\\s*$")){G=""}if(G!=""){z+="1#"+G+"|"}}if(listType=="npcs"){var D=Number(document.getElementById("minlevel").value);if(isNaN(D)){D=0}var f=Number(document.getElementById("maxlevel").value);if(isNaN(f)||f==0){f=255}if(D!=0||f!=255){z+="3#"+D+"-"+f+"|"}var G=document.getElementById("name").value;if(G.match("^\\s*$")){G=""}if(G!=""){z+="1#"+G+"|"}var l=document.getElementById("subtitle").value;if(l.match("^\\s*$")){l=""}if(l!=""){z+="2#"+l+"|"}}if(listType=="quests"){var D=Number(document.getElementById("minlevel").value);if(isNaN(D)){D=0}var f=Number(document.getElementById("maxlevel").value);if(isNaN(f)||f==0){f=255}if(D!=0||f!=255){z+="2#"+D+"-"+f+"|"}var d=document.getElementById("faction").value;if(d!=0){z+="3#"+d+"|"}var G=document.getElementById("name").value;if(G.match("^\\s*$")){G=""}if(G!=""){z+="1#"+G+"|"}var c=0;c=c|(((document.getElementById("type_normal").checked)?1:0)<<0);c=c|(((document.getElementById("type_group").checked)?1:0)<<1);c=c|(((document.getElementById("type_heroic").checked)?1:0)<<2);c=c|(((document.getElementById("type_dungeon").checked)?1:0)<<3);c=c|(((document.getElementById("type_raid").checked)?1:0)<<4);c=c|(((document.getElementById("type_pvp").checked)?1:0)<<5);c=c|(((document.getElementById("type_daily").checked)?1:0)<<6);c=c|(((document.getElementById("type_escort").checked)?1:0)<<7);if(c!=0&&c!=255){z+="4#"+c+"|"}}if(listType=="objects"){var G=document.getElementById("name").value;if(G.match("^\\s*$")){G=""}if(G!=""){z+="1#"+G+"|"}}if(listType=="zones"){var G=document.getElementById("name").value;if(G.match("^\\s*$")){G=""}if(G!=""){z+="1#"+G+"|"}}if(listType=="factions"){var G=document.getElementById("name").value;if(G.match("^\\s*$")){G=""}if(G!=""){z+="1#"+G+"|"}}if(listType=="achievements"){var G=document.getElementById("name").value;if(G.match("^\\s*$")){G=""}if(G!=""){z+="1#"+G+"|"}var y=document.getElementById("description").value;if(y.match("^\\s*$")){y=""}if(y!=""){z+="2#"+y+"|"}var d=document.getElementById("faction").value;if(d!=0){z+="3#"+d+"|"}var a=Number(document.getElementById("minpoints").value);if(isNaN(a)){a=0}var n=Number(document.getElementById("maxpoints").value);if(isNaN(n)||n==0){n=9999}if(a!=0||n!=9999){z+="4#"+a+"-"+n+"|"}}var h;var t=new Array();for(h=1;h<=filterCount;h++){var o=document.getElementById("filter"+h);if(o!=null){var e=document.getElementById("filtertype"+h).value;var E=e.split(":");var b=E[0];var B=E[1];var q=filterTypes[b][2];t.push(filterTypes[b]);z+=q+"#";if(B=="string"){z+=document.getElementById("filter"+h+"input_string").value}if(B=="bool"){z+=document.getElementById("filter"+h+"input_bool").value}if(B=="value"){z+=document.getElementById("filter"+h+"input_compare").value+";";z+=document.getElementById("filter"+h+"input_value").value}if(B=="list"){z+=document.getElementById("filter"+h+"input_list").value}z+="|"}}if(j!=null&&j==true){resultListStartAt=0}if(typeof processAutomaticColumnSetup=="function"){processAutomaticColumnSetup(t)}setFilterToUse(z)}function updateFilterDisplay(j){removeAllFilters();if(j!=false){document.filterform.reset()}var e=filterToUse.split("|");var g,d;for(g=0;g<e.length;g++){if(e[g].length>0){var b=e[g].split("#");var a=Number(b[0]);var f=b[1];var l=Number(b[1]);if(isNaN(l)){l=0}for(d=0;d<filterTypes.length;d++){if(a==filterTypes[d][2]){addFilter(a,f)}}if(g==0){if(a==1000){switchCategory(l,true)}else{switchCategory(currentcategory-(currentcategory%200),true)}}if(listType=="items"){if(a==1){document.getElementById("name").value=f}if(a==2){var c=f.split("-");document.getElementById("minplevel").value=(c[0]=="0")?"":c[0];document.getElementById("maxplevel").value=(c[1]=="0")?"":c[1]}if(a==3){var c=f.split("-");document.getElementById("minilevel").value=(c[0]=="0")?"":c[0];document.getElementById("maxilevel").value=(c[1]=="0")?"":c[1]}if(a==4){document.getElementById("q0").checked=(l&(1<<0))!=0;document.getElementById("q1").checked=(l&(1<<1))!=0;document.getElementById("q2").checked=(l&(1<<2))!=0;document.getElementById("q3").checked=(l&(1<<3))!=0;document.getElementById("q4").checked=(l&(1<<4))!=0;document.getElementById("q5").checked=(l&(1<<5))!=0;document.getElementById("q7").checked=(l&(1<<7))!=0}if(a==5){document.getElementById("nobind").checked=(l&(1<<0))!=0;document.getElementById("boe").checked=(l&(1<<2))!=0;document.getElementById("bou").checked=(l&(1<<3))!=0;document.getElementById("bop").checked=(l&(1<<1))!=0}if(a==6){document.getElementById("slot_head").checked=(l&(1<<0))!=0;document.getElementById("slot_neck").checked=(l&(1<<1))!=0;document.getElementById("slot_shoulder").checked=(l&(1<<2))!=0;document.getElementById("slot_back").checked=(l&(1<<3))!=0;document.getElementById("slot_chest").checked=(l&(1<<4))!=0;document.getElementById("slot_shirt").checked=(l&(1<<5))!=0;document.getElementById("slot_wrist").checked=(l&(1<<6))!=0;document.getElementById("slot_hands").checked=(l&(1<<7))!=0;document.getElementById("slot_waist").checked=(l&(1<<8))!=0;document.getElementById("slot_legs").checked=(l&(1<<9))!=0;document.getElementById("slot_feet").checked=(l&(1<<10))!=0;document.getElementById("slot_finger").checked=(l&(1<<11))!=0;document.getElementById("slot_trinket").checked=(l&(1<<12))!=0;document.getElementById("slot_tabard").checked=(l&(1<<13))!=0;document.getElementById("slot_mainhand").checked=(l&(1<<14))!=0;document.getElementById("slot_offhand").checked=(l&(1<<15))!=0;document.getElementById("slot_ranged").checked=(l&(1<<16))!=0;document.getElementById("slot_bag").checked=(l&(1<<17))!=0;document.getElementById("slot_none").checked=(l&(1<<18))!=0}}if(listType=="spells"){if(a==5){document.getElementById("school_physical").checked=(l&(1<<0))!=0;document.getElementById("school_holy").checked=(l&(1<<1))!=0;document.getElementById("school_fire").checked=(l&(1<<2))!=0;document.getElementById("school_nature").checked=(l&(1<<3))!=0;document.getElementById("school_frost").checked=(l&(1<<4))!=0;document.getElementById("school_shadow").checked=(l&(1<<5))!=0;document.getElementById("school_arcane").checked=(l&(1<<6))!=0}if(a==4){selectValueInList(document.getElementById("dispeltype"),l)}if(a==3){selectValueInList(document.getElementById("mechanic"),l)}if(a==2){var c=f.split("-");document.getElementById("minplevel").value=(c[0]=="0")?"":c[0];document.getElementById("maxplevel").value=(c[1]=="0")?"":c[1]}if(a==1){document.getElementById("name").value=f}if(a==17){document.getElementById("slot_head").checked=(l&(1<<0))!=0;document.getElementById("slot_neck").checked=(l&(1<<1))!=0;document.getElementById("slot_shoulder").checked=(l&(1<<2))!=0;document.getElementById("slot_back").checked=(l&(1<<3))!=0;document.getElementById("slot_chest").checked=(l&(1<<4))!=0;document.getElementById("slot_shirt").checked=(l&(1<<5))!=0;document.getElementById("slot_wrist").checked=(l&(1<<6))!=0;document.getElementById("slot_hands").checked=(l&(1<<7))!=0;document.getElementById("slot_waist").checked=(l&(1<<8))!=0;document.getElementById("slot_legs").checked=(l&(1<<9))!=0;document.getElementById("slot_feet").checked=(l&(1<<10))!=0;document.getElementById("slot_finger").checked=(l&(1<<11))!=0;document.getElementById("slot_trinket").checked=(l&(1<<12))!=0;document.getElementById("slot_tabard").checked=(l&(1<<13))!=0;document.getElementById("slot_mainhand").checked=(l&(1<<14))!=0;document.getElementById("slot_offhand").checked=(l&(1<<15))!=0;document.getElementById("slot_ranged").checked=(l&(1<<16))!=0;document.getElementById("slot_bag").checked=(l&(1<<17))!=0;document.getElementById("slot_none").checked=(l&(1<<18))!=0}if(a==18){var c=f.split("-");document.getElementById("minslevel").value=(c[0]=="0")?"":c[0];document.getElementById("maxslevel").value=(c[1]=="0")?"":c[1]}}if(listType=="itemsets"){if(a==2){var c=f.split("-");document.getElementById("minplevel").value=(c[0]=="0")?"":c[0];document.getElementById("maxplevel").value=(c[1]=="0")?"":c[1]}if(a==3){var c=f.split("-");document.getElementById("minilevel").value=(c[0]=="0")?"":c[0];document.getElementById("maxilevel").value=(c[1]=="0")?"":c[1]}if(a==4){selectValueInList(document.getElementById("class"),f)}if(a==5){selectValueInList(document.getElementById("tag"),f)}if(a==1){document.getElementById("name").value=f}}if(listType=="npcs"){if(a==3){var c=f.split("-");document.getElementById("minlevel").value=(c[0]=="0")?"":c[0];document.getElementById("maxlevel").value=(c[1]=="0")?"":c[1]}if(a==1){document.getElementById("name").value=f}if(a==2){document.getElementById("subtitle").value=f}}if(listType=="quests"){if(a==2){var c=f.split("-");document.getElementById("minlevel").value=(c[0]=="0")?"":c[0];document.getElementById("maxlevel").value=(c[1]=="0")?"":c[1]}if(a==1){document.getElementById("name").value=f}if(a==3){selectValueInList(document.getElementById("faction"),l)}if(a==4){document.getElementById("type_normal").checked=(l&(1<<0))!=0;document.getElementById("type_group").checked=(l&(1<<1))!=0;document.getElementById("type_heroic").checked=(l&(1<<2))!=0;document.getElementById("type_dungeon").checked=(l&(1<<3))!=0;document.getElementById("type_raid").checked=(l&(1<<4))!=0;document.getElementById("type_pvp").checked=(l&(1<<5))!=0;document.getElementById("type_daily").checked=(l&(1<<6))!=0;document.getElementById("type_escort").checked=(l&(1<<7))!=0}}if(listType=="objects"){if(a==1){document.getElementById("name").value=f}}if(listType=="zones"){if(a==1){document.getElementById("name").value=f}}if(listType=="factions"){if(a==1){document.getElementById("name").value=f}}if(listType=="achievements"){if(a==1){document.getElementById("name").value=f}if(a==2){document.getElementById("description").value=f}if(a==3){selectValueInList(document.getElementById("faction"),l)}if(a==4){var h=f.split("-");document.getElementById("minpoints").value=(h[0]=="0")?"":h[0];document.getElementById("maxpoints").value=(h[1]=="0")?"":h[1]}}}}updateFilterOperatorDisplay()}function updateFilterOperatorDisplay(){var a=document.getElementsByName("filterop");if(a!=null&&a.length>0){if(resultListFilterOp=="or"){a[1].checked=true}else{a[0].checked=true}}}function setFilterToUse(a){filterToUse=a;resultListData=new Array();displayResultList(resultListSortBy,resultListSortDirection,resultListStartAt)}var resultListData=new Array();var filterToUse="empty";var resultListStartAt=0;var resultListSortBy=(typeof(defaultSortColumn)!=="undefined"?defaultSortColumn:null);var resultListSortDirection=(typeof(defaultSortDirection)!=="undefined"?defaultSortDirection:null);var resultListFilterOp="and";function resortResultList(c,b,a){resultListData=new Array();displayResultList(c,b,a)}function changeResultListSize(){var a=this.value;displayCountPerPage=Number(a);resultListData=new Array();displayResultList(resultListSortBy,resultListSortDirection,0)}var preventListSaving=true;function displayResultList(v,K,x){var M=null;var a;var O,L;for(O=1;O<resultListData.length;O++){var u=resultListData[O][0];var n=u+resultListData[O][1];if(x>=u&&x<n){M=resultListData[O][2];a=Number(resultListData[O][0]);break}}if(M==null){resultListStartAt=x;resultListSortBy=v;resultListSortDirection=K;displayLoadingScreen();var A="";for(O=0;O<columnsToUse.length;O++){if(v==O&&K==0){A+="a"}if(v==O&&K==1){A+="d"}A+=columnsToUse[O]+"x"}var I=null;if(typeof convertRatingOptionsToString=="function"){try{I=convertRatingOptionsToString();if(I==""){I=null}}catch(Q){I=null}}resultListFilterOp="and";var C=document.getElementsByName("filterop");if(C!=null&&C.length>0&&C[1].checked==true){resultListFilterOp="or"}postAJAXListRequest(listType,filterToUse,A,x-(x%displayCountPerPage),displayCountPerPage,resultListFilterOp,I);return}var g=resultListData[0][0];var j=g-x;if(j>displayCountPerPage){j=displayCountPerPage}var F=document.getElementById("listbody");var l=document.getElementById("listcontent");if(l!=null){F.removeChild(l)}var b=(K+1)%2;l=getListContentTable();var G=document.createElement("thead");var m=document.createElement("tr");var E=getColumnInfo(resultListData[0].slice(1));for(O=0;O<E.length;O++){m.appendChild(getListContentHeader((O==0),E[O][3],"javascript:resortResultList("+O+","+((v==O)?b:1)+","+x+");",E[O][2],(v==O)?K:-1))}G.appendChild(m);l.appendChild(G);var R=document.createElement("tbody");R.className="listbody";for(O=0;O<j;O++){var h;if(listType=="items"){h="item?id="}if(listType=="spells"){h="spell?id="}if(listType=="itemsets"){h="itemset?id="}if(listType=="npcs"){h="npc?id="}if(listType=="quests"){h="quest?id="}if(listType=="objects"){h="object?id="}if(listType=="zones"){h="zone?id="}if(listType=="factions"){h="faction?id="}if(listType=="achievements"){h="achievement?id="}var w=createResultLine(E,M[O+x-a],h);R.appendChild(w)}l.appendChild(R);l.id="listcontent";F.appendChild(l);var y=document.getElementById("listheader");var B=document.getElementById("listfooter");removeAllChilds(y.firstChild.firstChild);y.firstChild.firstChild.appendChild(document.createTextNode("Einträge pro Seite: "));var J=document.createElement("select");J.onchange=changeResultListSize;for(O=1;O<=5;O++){var S=document.createElement("option");S.value=O*50;if(O*50==displayCountPerPage){S.defaultSelected=true}S.appendChild(document.createTextNode(O*50));J.appendChild(S)}y.firstChild.firstChild.appendChild(J);var P=document.createElement("img");P.src="images/blank.gif";P.width=24;P.height=16;y.firstChild.firstChild.appendChild(P);if(x>0){var p=0;var z=document.createElement("a");z.href="javascript:displayResultList("+v+","+K+","+p+");";z.appendChild(document.createTextNode("|<"));y.firstChild.firstChild.appendChild(z);y.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"));if(x-displayCountPerPage*5>=0){var q=x-displayCountPerPage*5;var t=document.createElement("a");t.href="javascript:displayResultList("+v+","+K+","+q+");";t.appendChild(document.createTextNode("<<"));y.firstChild.firstChild.appendChild(t);y.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"))}var r=x-displayCountPerPage;var o=document.createElement("a");o.href="javascript:displayResultList("+v+","+K+","+r+");";o.appendChild(document.createTextNode("<"));y.firstChild.firstChild.appendChild(o);y.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"))}var s=(x+1)+" - "+(x+j)+" von "+g;y.firstChild.firstChild.appendChild(document.createTextNode(s));y.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"));if(x+displayCountPerPage<g){var f=x+displayCountPerPage;var D=document.createElement("a");D.href="javascript:displayResultList("+v+","+K+","+f+");";D.appendChild(document.createTextNode(">"));y.firstChild.firstChild.appendChild(D);y.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"));if(x+displayCountPerPage*5<g){var d=x+displayCountPerPage*5;var H=document.createElement("a");H.href="javascript:displayResultList("+v+","+K+","+d+");";H.appendChild(document.createTextNode(">>"));y.firstChild.firstChild.appendChild(H);y.firstChild.firstChild.appendChild(document.createTextNode("\u00A0\u00A0"))}var c=g-(g%displayCountPerPage);if(c==g){c-=displayCountPerPage}var N=document.createElement("a");N.href="javascript:displayResultList("+v+","+K+","+c+");";N.appendChild(document.createTextNode(">|"));y.firstChild.firstChild.appendChild(N)}B.firstChild.replaceChild(y.firstChild.firstChild.cloneNode(true),B.firstChild.firstChild);B.getElementsByTagName("select")[0].onchange=changeResultListSize;if(preventListSaving==false){saveListSettingsToURL()}preventListSaving=false;skipUpdatingBackground=false;checkWindowSize()}function getColumnInfo(d){var f=0;var c;for(c=0;c<d.length;c++){f+=columnInfo[d[c]-1][2]}var b=1/f;var a=new Array();for(c=0;c<d.length;c++){var e=new Array();e.push(d[c]);e.push(columnInfo[d[c]-1][1]);e.push(columnInfo[d[c]-1][0]);e.push(Math.round(columnInfo[d[c]-1][2]*b*100)+"%");a.push(e)}return a}function postAJAXListRequest(j,f,c,b,h,d,a){skipUpdatingBackground=true;displayLoadingScreen();var g=-1;if(d=="or"&&typeof filterOpOrStart=="number"){g=filterOpOrStart}var e=j+"?filter="+encodeURIComponent(f)+"&col="+c+"&start="+b+"&count="+h+"&op="+g;if(a!=null){e+="&rating="+encodeURIComponent(a)}startAJAXRequest(e,processAJAXListResponse)}function processAJAXListResponse(b){b=evaluateArray(b);var h,e;var a;var g=new Array();var d=new Array();for(h=0;h<b.length;h++){if(b[h]!=null){var f=b[h];if(h==0){resultListData[0]=new Array();resultListData[0].push(Number(f[0]));g.push(Number(f[1]));g.push(Number(f[2]));var c=f[3].split("x");for(e=0;e<c.length;e++){var j=Number(c[e]);if(!isNaN(j)&&c[e]!=""){resultListData[0].push(j)}}}else{d.push(f)}}}g.push(d);resultListData.push(g);displayResultList(resultListSortBy,resultListSortDirection,resultListStartAt)}function createResultLine(J,A,f){var U,T;listcontent_tr=document.createElement("tr");listcontent_tr.onclick=new Function("document.location.href='"+f+A[0]+"'");listcontent_tr.className="clickable";for(U=0;U<J.length;U++){var R=J[U][1];var M=A[U+1];if(R=="iconname"||R=="taggediconname"){var H=(R=="taggediconname"?1:0);var q=document.createElement("a");q.href=f+A[0];q.className="q"+M[2];if(q.className=="q1"){q.className="q1b"}var t;if(R=="taggediconname"){t=getItemIcon(M[3],null,M[4+H],1,1,"medium",null,null,null,null,null,null,M[4])}else{t=getItemIcon(M[3],null,M[4+H],1,1,"medium")}q.appendChild(document.createTextNode(M[0]));if(M[4+H]!=null){addTooltip(q,M[4+H])}var O=document.createElement("span");O.className="listelement_iconname_text_table";O.appendChild(q);if(M[1]!=""){var o=document.createElement("span");o.className="listelement_iconname_subtext";o.appendChild(document.createTextNode(M[1]));O.appendChild(document.createElement("br"));O.appendChild(o)}var x=document.createElement("table");var p=document.createElement("tbody");x.appendChild(p);x.cellPadding=0;x.cellSpacing=0;listcontent_tr_name_table_tr=document.createElement("tr");p.appendChild(listcontent_tr_name_table_tr);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.width=44;listcontent_tr_name_table_tr_td.appendChild(t);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);listcontent_tr_name_table_tr_td=document.createElement("td");listcontent_tr_name_table_tr_td.align="left";listcontent_tr_name_table_tr_td.vAlign="middle";listcontent_tr_name_table_tr_td.appendChild(O);listcontent_tr_name_table_tr.appendChild(listcontent_tr_name_table_tr_td);var L=getListTableElement("left",x);listcontent_tr.appendChild(L)}if(R=="qualityname"){var y=document.createElement("div");y.className="bold";var q=document.createElement("a");q.href=f+A[0];q.className="q"+M[2];if(q.className=="q1"){q.className="q1b"}q.appendChild(document.createTextNode(M[0]));var v=document.createElement("div");v.className="listelement_iconname_text";var K=document.createElement("div");K.appendChild(q);if(M[1]!=""){var o=document.createElement("span");o.className="listelement_iconname_subtext";o.appendChild(document.createTextNode(M[1]));K.appendChild(document.createElement("br"));K.appendChild(o)}v.appendChild(K);y.appendChild(v);var L=getListTableElement("left",y);listcontent_tr.appendChild(L)}if(R=="subtitledname"||R=="subtitledtooltippedname"){var y=document.createElement("div");y.className="bold";var q=document.createElement("a");q.href=f+A[0];q.appendChild(document.createTextNode(M[0]));var v=document.createElement("div");v.className="listelement_iconname_text";var K=document.createElement("div");K.appendChild(q);if(M[1]!=""&&M[2]!=null){var o=document.createElement("span");o.className="listelement_iconname_subtext";o.appendChild(document.createTextNode(M[1]));K.appendChild(document.createElement("br"));K.appendChild(o)}v.appendChild(K);y.appendChild(v);var L=getListTableElement("left",y);if(R=="subtitledtooltippedname"&&M[2]!=""&&M[2]!=null){addTooltip(L,M[2])}listcontent_tr.appendChild(L)}if(R=="name"){var q=document.createElement("a");q.className="bold";q.href=f+A[0];q.appendChild(document.createTextNode(M));var L=getListTableElement("left",q);listcontent_tr.appendChild(L)}if(R=="tooltippedname"){var q=document.createElement("a");q.className="bold";q.href=f+A[0];q.appendChild(document.createTextNode(M[0]));var L=getListTableElement("left",q);if(M[1]!=""&&M[1]!=null){addTooltip(L,M[1])}listcontent_tr.appendChild(L)}if(R=="questrewards"){var W=getListTableElement("center",null);var S;var h=document.createElement("table");h.border=0;h.cellPadding=0;h.cellSpacing=0;var Y=document.createElement("tbody");var I=document.createElement("tr");var N=0;var G;for(G=0;G<M[0].length;G++){S=document.createElement("td");listcontent_tr_rewards_content_table=document.createElement("table");listcontent_tr_rewards_content_table.width=32;listcontent_tr_rewards_content_table.border=0;listcontent_tr_rewards_content_table.cellPadding=0;listcontent_tr_rewards_content_table.cellSpacing=0;listcontent_tr_rewards_content_table_tbody=document.createElement("tbody");listcontent_tr_rewards_content_table_tr=document.createElement("tr");listcontent_tr_rewards_content_table_td=document.createElement("td");listcontent_tr_rewards_content_table_td.align="left";addItemIcon(listcontent_tr_rewards_content_table_td,M[0][G][1],"item?id="+M[0][G][0],M[0][G][2],Number(M[0][G][3]),Number(M[0][G][3]),"small");listcontent_tr_rewards_content_table_tr.appendChild(listcontent_tr_rewards_content_table_td);listcontent_tr_rewards_content_table_tbody.appendChild(listcontent_tr_rewards_content_table_tr);listcontent_tr_rewards_content_table.appendChild(listcontent_tr_rewards_content_table_tbody);S.appendChild(listcontent_tr_rewards_content_table);I.appendChild(S);N++}for(G=0;G<M[1].length;G++){if(G==0){var a;if(N>0){a=document.createTextNode(" und eines von:")}else{a=document.createTextNode("eines von: ")}S=document.createElement("td");S.appendChild(a);I.appendChild(S)}S=document.createElement("td");listcontent_tr_rewards_content_table=document.createElement("table");listcontent_tr_rewards_content_table.width=32;listcontent_tr_rewards_content_table.border=0;listcontent_tr_rewards_content_table.cellPadding=0;listcontent_tr_rewards_content_table.cellSpacing=0;listcontent_tr_rewards_content_table_tbody=document.createElement("tbody");listcontent_tr_rewards_content_table_tr=document.createElement("tr");listcontent_tr_rewards_content_table_td=document.createElement("td");listcontent_tr_rewards_content_table_td.align="left";addItemIcon(listcontent_tr_rewards_content_table_td,M[1][G][1],"item?id="+M[1][G][9],M[1][G][2],Number(M[1][G][3]),Number(M[1][G][3]),"small");listcontent_tr_rewards_content_table_tr.appendChild(listcontent_tr_rewards_content_table_td);listcontent_tr_rewards_content_table_tbody.appendChild(listcontent_tr_rewards_content_table_tr);listcontent_tr_rewards_content_table.appendChild(listcontent_tr_rewards_content_table_tbody);S.appendChild(listcontent_tr_rewards_content_table);I.appendChild(S);N++}if(S!=null){I.appendChild(S)}Y.appendChild(I);h.appendChild(Y);W.appendChild(h);listcontent_tr.appendChild(W)}if(R=="playerfaction"){var w=getListTableElement("center",null);var m=Number(M);if((m&1)!=0){var B=document.createElement("img");B.src="images/faction_alliance.png";w.appendChild(B)}if((m&2)!=0){var C=document.createElement("img");C.src="images/faction_horde.png";w.appendChild(C)}listcontent_tr.appendChild(w)}if(R=="int"){var c=getListTableElement("center",document.createTextNode(M));listcontent_tr.appendChild(c)}if(R=="intrange"){if(M.length==2){var r=M[0];if(M[1]!=M[0]){r+=" - "+M[1]}var c=getListTableElement("center",document.createTextNode(r));listcontent_tr.appendChild(c)}else{var c=getListTableElement("center",null);listcontent_tr.appendChild(c)}}if(R=="npclevel"){if(M.length==3){var r=M[0];if(M[1]!=M[0]){r+=" - "+M[1]}if(M[0]<=0){r="???"}var D=document.createElement("div");D.appendChild(document.createTextNode(r));if(M[2]!=""){var b=document.createElement("div");b.className="lilbitsmallertext";b.appendChild(document.createTextNode(M[2]));D.appendChild(b)}var c=getListTableElement("center",D);listcontent_tr.appendChild(c)}}if(R=="money"){var e=getListTableElement("center",null);addMoney(e,M);listcontent_tr.appendChild(e)}if(R=="decimal"){var F=getListTableElement("center",document.createTextNode(M));listcontent_tr.appendChild(F)}if(R=="string"){var Q=getListTableElement("center",document.createTextNode(M));listcontent_tr.appendChild(Q)}if(R=="linkedstring"){var Q=getListTableElement("center",null);if(M.length==2){getLinkElement(M[0],M[1],Q)}else{Q.appendChild(document.createTextNode((M.length==1?M[0]:"")))}listcontent_tr.appendChild(Q)}if(R=="source"){var Q=getListTableElement("center",null);if(M[0]!=""){if(M[1]!=""){getLinkElement(M[0],M[1],Q)}else{Q.appendChild(document.createTextNode(M[0]))}}if(M[2]!=""){Q.appendChild(document.createElement("br"));var V=document.createElement("span");V.className="smalltext";getLinkElement(M[2],M[3],V);Q.appendChild(V)}listcontent_tr.appendChild(Q)}if(R=="zonelist"){var Q=getListTableElement("center",null);for(T=0;T<M.length;T++){if(T>0){Q.appendChild(document.createTextNode(", "))}if(typeof M[T]!="number"){var E=document.createElement("a");E.href="zone?id="+M[T][1];E.appendChild(document.createTextNode(M[T][0]));Q.appendChild(E)}else{Q.appendChild(document.createTextNode(" ("+M[T]+" weitere)"))}}listcontent_tr.appendChild(Q)}if(R=="skillAndLevel"){if(M.length==2){var s=getListTableElement("center",document.createTextNode(M[0]));var ab=document.createElement("div");ab.appendChild(document.createTextNode(M[1]));ab.className="lilbitsmallertext";s.appendChild(ab);listcontent_tr.appendChild(s)}else{var s=getListTableElement("center",document.createTextNode(""));listcontent_tr.appendChild(s)}}if(R=="reagents"){if(browserIsOpera){var X=document.createElement("table");X.cellPadding=2;X.cellSpacing=2;var l=document.createElement("tbody");var P=document.createElement("tr");for(T=0;T<M.length;T++){var aa=document.createElement("td");aa.appendChild(getItemIcon(M[T][1],"item?id="+M[T][0],M[T][2],M[T][3],M[T][3],"small"));P.appendChild(aa)}l.appendChild(P);X.appendChild(l);var Z=getListTableElement("left",X);listcontent_tr.appendChild(Z)}else{var Z=getListTableElement("left",X);for(T=0;T<M.length;T++){Z.appendChild(getItemIcon(M[T][1],"item?id="+M[T][0],M[T][2],M[T][3],M[T][3],"small"))}listcontent_tr.appendChild(Z)}}if(R=="rating"){if(!isNaN(Number(M))){var c=getListTableElement("center",document.createTextNode(M));listcontent_tr.appendChild(c)}else{var j=M[0];var d="[";for(T=1;T<M.length;T+=2){if(d!="["){d+=","}d+="["+(M[T]-1)+","+M[T+1]+"]"}d+="]";var g=document.createElement("div");g.appendChild(document.createTextNode(j));g.onmouseover=new Function("displayRatingTooltip(this, "+d+");");g.onmouseout=new Function("hideRatingTooltip();");g.style.position="relative";var n=getListTableElement("center",g);listcontent_tr.appendChild(n)}}if(R=="itemcompare"){var g=document.createElement("div");g.className="lilbitsmallertext";getLinkElement("einfügen in Slot 1","itemcompare?action=setitem&slot=0&id="+M,g);g.appendChild(document.createElement("br"));getLinkElement("einfügen in Slot 2","itemcompare?action=setitem&slot=1&id="+M,g);g.appendChild(document.createElement("br"));getLinkElement("einfügen in Slot 3","itemcompare?action=setitem&slot=2&id="+M,g);var u=getListTableElement("center",g);listcontent_tr.appendChild(u)}}return listcontent_tr}function toggleColumnOptions(){var j=document.getElementById("columnlist");removeAllChilds(j);var g=document.createElement("table");g.border=0;g.cellspacing=0;g.cellpadding=2;var f=document.createElement("tbody");var e,c;for(e=0;e<Math.ceil(columnInfo.length/2);e++){var d=document.createElement("tr");for(c=0;c<2;c++){if(e*2+c<columnInfo.length){var a=document.createElement("td");a.align="left";var h=document.createElement("input");h.type="checkbox";h.id="colOption"+(e*2+c+1);h.defaultChecked=false;if(e+c==0){h.disabled=true;h.defaultChecked=true;h.checked=true}a.appendChild(h);a.appendChild(document.createTextNode(" "+columnInfo[e*2+c][0]));d.appendChild(a)}}f.appendChild(d)}g.appendChild(f);j.appendChild(g);j.appendChild(document.createElement("br"));var b=document.createElement("input");b.type="button";b.value="OK";b.onclick=new Function("setColumnOptions()");j.appendChild(b);for(e=0;e<columnsToUse.length;e++){document.getElementById("colOption"+columnsToUse[e]).defaultChecked=true;document.getElementById("colOption"+columnsToUse[e]).checked=true}MM_changeProp("columnlist","style.left",110);MM_changeProp("columnlist","style.top",0);MM_toggleLayers("columnlist")}function setColumnOptions(){newColumnsToUse=new Array();for(i=0;i<columnInfo.length;i++){var a=document.getElementById("colOption"+(i+1));if(a.checked==true){newColumnsToUse.push(i+1)}}MM_toggleLayers("columnlist");columnsToUse=newColumnsToUse;resortResultList(resultListSortBy,resultListSortDirection,resultListStartAt)}function updateFilterPresetList(){var b;var e=document.getElementById("filterpresets");var d=null;for(b=0;b<=filterPresets.length;b++){if(b<filterPresets.length&&filterPresets[b][1]=="header"){var a=document.createElement("optgroup");a.label=filterPresets[b][0];e.appendChild(a);d=a}else{var c=document.createElement("option");if(b<filterPresets.length){c.appendChild(document.createTextNode(filterPresets[b][0]));c.value=b}else{c.appendChild(document.createTextNode("Benutzerdefiniert"));c.value=-1}if(d!=null){d.appendChild(c)}else{e.appendChild(c)}}}setSelectedFilterPreset(null)}function setSelectedFilterPreset(b){var e=document.getElementById("filterpresets");if(e==null){return}var c,a;if(b==null){b=-1}var d=0;for(c=0;c<e.childNodes.length;c++){if(e.childNodes[c].nodeName=="OPTGROUP"){for(a=0;a<e.childNodes[c].childNodes.length;a++){if(e.childNodes[c].childNodes[a].nodeName=="OPTION"){if(e.childNodes[c].childNodes[a].value==b){e.selectedIndex=d}d++}}}else{if(e.childNodes[c].nodeName=="OPTION"){if(e.childNodes[c].value==b){e.selectedIndex=d}d++}}}}function applyFilterPreset(){var b=document.getElementById("filterpresets");var a=b.value;if(a>=0&&a<filterPresets.length){setFilterPreset(filterPresets[a]);setSelectedFilterPreset(a)}}function setFilterPreset(a){filterToUse=a[1];if(currentcategory%200!=0){filterToUse="1000#"+currentcategory+"|"+filterToUse}if(a[2]=="or"){resultListFilterOp="or"}else{resultListFilterOp="and"}updateFilterDisplay(false)}var ratingsettings=[];function toggleRatingOptions(){var h=document.getElementById("configcontent");var g=document.getElementById("ratingoptions");if(g!=null){h.removeChild(g);return}g=document.createElement("div");g.id="ratingoptions";var q,p;var l=document.createElement("table");l.width=1100;l.cellSpacing=0;l.cellPadding=2;var j=document.createElement("tbody");var d=document.createElement("tr");var b=document.createElement("span");b.className="lilbitsmallertext";getLinkElement("Was kann man hiermit machen?","static_help_rating",b);d.appendChild(getListTableElement("left",b,252));d.appendChild(getListTableElement("center",document.createTextNode("Faktor"),80));d.appendChild(getListTableElement("center",document.createTextNode("Minimum"),80));d.appendChild(getListTableElement("center",document.createTextNode("Maximum"),80));d.appendChild(getListTableElement("center",null,80));d.appendChild(getListTableElement("left",null,252));d.appendChild(getListTableElement("center",document.createTextNode("Faktor"),80));d.appendChild(getListTableElement("center",document.createTextNode("Minimum"),80));d.appendChild(getListTableElement("center",document.createTextNode("Maximum"),80));j.appendChild(d);var a=["url('images/elementbg/white_10.png') repeat",""];for(q=0;q<ratingInfo.length;q+=2){d=document.createElement("tr");for(p=0;p<2;p++){if(q+p<ratingInfo.length){d.appendChild(getListTableElement("left",document.createTextNode(ratingInfo[q+p]),252,a[q%4/2]));d.appendChild(getListTableElement("center",getTextInputField("val"+(q+p),8),80,a[q%4/2]));d.appendChild(getListTableElement("center",getTextInputField("min"+(q+p),8),80,a[q%4/2]));d.appendChild(getListTableElement("center",getTextInputField("max"+(q+p),8),80,a[q%4/2]));if(p==0){d.appendChild(getListTableElement("center",null,80))}}else{d.appendChild(getListTableElement("left",null,542,null,4))}}j.appendChild(d)}d=document.createElement("tr");var t=getListTableElement("center",null,1100,null,9);var c=document.createElement("div");c.className="ratingpersistence";var s=document.createElement("table");s.cellSpacing=0;s.cellPadding=2;s.width=1086;var m=document.createElement("tbody");var f=document.createElement("tr");var u=document.createElement("td");u.width="40%";u.align="center";u.appendChild(document.createTextNode("Bewertungsschema speichern"));f.appendChild(u);u=document.createElement("td");u.width="20%";u.align="center";u.appendChild(getButton("OK",setRatingOptions));u.appendChild(document.createTextNode(" "));u.appendChild(getButton("Reset",resetRatingOptions));f.appendChild(u);u=document.createElement("td");u.width="40%";u.align="center";u.appendChild(document.createTextNode("Bewertungsschema laden"));f.appendChild(u);m.appendChild(f);f=document.createElement("tr");u=document.createElement("td");u.width="40%";u.align="center";u.appendChild(document.createTextNode("Name: "));u.appendChild(getTextInputField("ratingsavename",20));u.appendChild(document.createTextNode(" "));u.appendChild(getButton("speichern",saveRatingOptions));f.appendChild(u);u=document.createElement("td");u.width="20%";f.appendChild(u);u=document.createElement("td");u.width="40%";u.align="center";u.appendChild(document.createTextNode("Name: "));var e=document.createElement("select");e.id="ratingsetuplist";u.appendChild(e);u.appendChild(document.createTextNode(" "));u.appendChild(getButton("laden",loadRatingOptions));u.appendChild(document.createTextNode(" "));u.appendChild(getButton("löschen",deleteRatingOptions));f.appendChild(u);m.appendChild(f);s.appendChild(m);c.appendChild(s);t.appendChild(c);d.appendChild(t);j.appendChild(d);l.appendChild(j);g.appendChild(l);h.appendChild(g);for(q=0;q<ratingInfo.length;q++){var o="";var n="";var r="";for(p=0;p<ratingsettings.length;p++){if(ratingsettings[p][0]==q){o=ratingsettings[p][1];n=ratingsettings[p][2];r=ratingsettings[p][3]}}document.getElementById("val"+q).value=o;document.getElementById("min"+q).value=n;document.getElementById("max"+q).value=r}loadRatingOptionsList()}function setRatingOptions(e){ratingsettings=[];var a;for(a=0;a<ratingInfo.length;a++){var c,b,d;c=trimString(document.getElementById("val"+a).value);b=trimString(document.getElementById("min"+a).value);d=trimString(document.getElementById("max"+a).value);if(c!=null&&c!=""){ratingsettings.push([a,c,b,d])}}if(e==true){return}toggleRatingOptions();autoSetupRatingColumn();resortResultList(resultListSortBy,resultListSortDirection,resultListStartAt)}function resetRatingOptions(){ratingsettings=[];toggleRatingOptions();autoSetupRatingColumn()}function autoSetupRatingColumn(){var a;var b=-1;var c=false;for(a=0;a<columnsToUse.length;a++){if(columnsToUse[a]==ratingColumn){b=a}}if(b==-1&&ratingsettings.length>0){columnsToUse.push(ratingColumn);c=true}if(b!=-1&&ratingsettings.length==0){columnsToUse.pop();c=true}if(c==true){resortResultList(resultListSortBy,resultListSortDirection,resultListStartAt)}}function convertRatingOptionsToString(){var a="";var b;for(b=0;b<ratingsettings.length;b++){var f=ratingsettings[b][0];var d=ratingsettings[b][1];var c=ratingsettings[b][2];var e=ratingsettings[b][3];a+=(f+1)+"x"+d+"x"+c+"x"+e+";"}return a}function convertStringToRatingOptions(d){var a;var f=d.split(";");ratingsettings=[];for(a=0;a<f.length;a++){var e=f[a].split("x");if(e.length==4){var h=Number(e[0])-1;var c=e[1];var b=e[2];var g=e[3];ratingsettings.push([h,c,b,g])}}}function displayRatingTooltip(g,d){var n=document.getElementById("ratingtooltip");if(n!=null){return}n=document.createElement("div");n.id="ratingtooltip";var c=document.createElement("table");c.cellPadding=2;c.cellSpacing=0;var m=document.createElement("tbody");var e;for(e=0;e<d.length;e++){var b=ratingInfo[d[e][0]];var l=d[e][1];var a=document.createElement("tr");var h=document.createElement("td");h.width=120;h.align="left";h.className="lilbitsmallertext";h.bgColor=(e%2==1)?"#222222":"000000";h.appendChild(document.createTextNode(b));a.appendChild(h);h=document.createElement("td");h.width=72;h.align="right";var j="neutralrating";var f="";if(l>0){j="positiverating";f="+"}if(l<0){j="negativerating"}h.className="lilbitsmallertext "+j;h.bgColor=(e%2==1)?"#222222":"000000";h.appendChild(document.createTextNode(f+l));a.appendChild(h);m.appendChild(a)}c.appendChild(m);n.appendChild(c);g.appendChild(n)}function hideRatingTooltip(){var a=document.getElementById("ratingtooltip");if(a==null){return}a.parentNode.removeChild(a)}function saveRatingOptions(){setRatingOptions(true);var a=document.getElementById("ratingsavename").value;var c=convertRatingOptionsToString();var b="items?action=saverating&name="+encodeURIComponent(a)+"&data="+encodeURIComponent(c);startAJAXRequest(b,processAJAXSaveRatingOptionsResponse)}function processAJAXSaveRatingOptionsResponse(a){alert(a);loadRatingOptionsList()}function loadRatingOptions(){var b=Number(document.getElementById("ratingsetuplist").value);if(isNaN(b)||(b==-1)){return}var a="items?action=getrating&id="+b;startAJAXRequest(a,processAJAXLoadRatingOptionsResponse)}function processAJAXLoadRatingOptionsResponse(a){if(a==null||a==""){alert("Beim Laden der Bewertungseinstellung ist ein Fehler aufgetreten.");return}convertStringToRatingOptions(a);toggleRatingOptions();toggleRatingOptions()}function loadRatingOptionsList(){var a="items?action=ratinglist";startAJAXRequest(a,processAJAXRatingOptionsListResponse)}function processAJAXRatingOptionsListResponse(d){var a=document.getElementById("ratingsetuplist");removeAllChilds(a);if(d==null||d==""){var c=document.createElement("option");c.value=-1;c.appendChild(document.createTextNode("keine vorhanden"));a.appendChild(c);return}var f=d.split(";");var b;for(b=0;b<f.length;b++){var e=f[b].split("#");if(e.length==2){var c=document.createElement("option");c.value=e[0];c.appendChild(document.createTextNode(e[1]));a.appendChild(c)}}}function deleteRatingOptions(){var b=Number(document.getElementById("ratingsetuplist").value);if(isNaN(b)||(b==-1)){return}var a="items?action=deleterating&id="+b;startAJAXRequest(a,processAJAXSaveRatingOptionsResponse)}function processAutomaticColumnSetup(n){var m=new Array();var e,d,c;for(e=0;e<n.length;e++){var a=n[e];if(a.length>=5){var j=a[a.length-1];for(d=0;d<j.length;d++){var b=j[d];var p=false;for(c=0;c<m;c++){if(m[c]==b){p=true}}if(!p){m.push(b)}}}}var h=0;for(e=0;e<columnInfo.length;e++){var g=false;var b=columnInfo[e];if(b.length>=4){var o=b[3];if(o=="default"){columnsToUse.push(e+1);h++}}}for(e=0;e<m.length;e++){var b=m[e];if(b!="default"){for(d=0;d<columnInfo.length;d++){var f=columnInfo[d];if(f.length>=4&&f[3]==b){columnsToUse.push(d+1)}}}}columnsToUse=cleanupColumnList(columnsToUse);if(m.length==0){resultListSortBy=defaultSortColumn;resultListSortDirection=defaultSortDirection}else{resultListSortBy=h;resultListSortDirection=1}}function numsort_asc(d,c){return d-c}function cleanupColumnList(b){b.sort(numsort_asc);var a;var c=-1;for(a=0;a<b.length;a++){if(b[a]>c){c=b[a]}else{b.splice(a,1);a--}}return b};
