1 2 3function WWStoggle(id, display) { 4 var div = document.getElementById(id); 5 if (div.style.display == 'none') { 6 div.style.display = (display != undefined ? display : "block"); 7 div.style.visibility = 'visible'; 8 } 9 else { 10 div.style.display = 'none'; 11 div.style.visibility = 'collapse'; 12 } 13} 14function toggleTeaser() { 15 WWStoggle("hiscore-teaser-km", "block"); 16 WWStoggle("hiscore-teaser-mj", "block"); 17} 18 19 20function changeDatetimes() { 21 var elements = document.getElementsByClassName("datetime"); 22 for (var i = elements.length-1; i >= 0; i--) { 23 var el = elements[i]; 24 var d = new Date(el.innerHTML); 25 var options = new Object(); 26 options.dateStyle = "medium"; 27 options.timeStyle = "short"; 28 el.innerHTML = d.toLocaleString(undefined, options); 29 el.className = ""; 30 } 31 elements = document.getElementsByClassName("date"); 32 for (var i = elements.length - 1; i >= 0; i--) { 33 var el = elements[i]; 34 var d = new Date(el.innerHTML); 35 el.innerHTML = d.toLocaleDateString(); 36 el.className = ""; 37 } 38} 39 40function WTPtoggle(id) { 41 var div = document.getElementById(id); 42 WTPtoggleE(div); 43} 44function WTPtoggleE(div) { 45 $(div).animate({ height: 'toggle' }); 46} 47var wtpMenuVisible = false; 48var wtpUserVisible = false; 49var wtpLangVisible = false; 50 51var lastMenu2Container = null; 52function WTPtoggleSubMenu2(item) { 53 var p = item.parentElement; 54 var cont = p.nextSibling; 55 if (lastMenu2Container != null && lastMenu2Container != item) 56 WTPtoggleSubMenu2(lastMenu2Container); 57 WTPtoggleE(cont); 58 lastMenu2Container = item != lastMenu2Container ? item : null; 59 var img = item.getElementsByTagName("img"); 60 if (img != null && img.length > 0) { 61 if (lastMenu2Container != null) 62 img[0].src = "/fileadmin/templates/images2/down.png"; 63 else img[0].src = "/fileadmin/templates/images2/right.png"; 64 } 65} 66var lastMenu3Container = null; 67function WTPtoggleSubMenu3(item) { 68 var p = item.parentElement; 69 var cont = p.nextSibling; 70 if (lastMenu3Container != null && lastMenu3Container != item) 71 WTPtoggleSubMenu3(lastMenu3Container); 72 WTPtoggleE(cont); 73 lastMenu3Container = item != lastMenu3Container ? item : null; 74 var img = item.getElementsByTagName("img"); 75 if (img != null && img.length > 0) { 76 if (lastMenu3Container != null) 77 img[0].src = "/fileadmin/templates/images2/down.png"; 78 else img[0].src = "/fileadmin/templates/images2/right.png"; 79 } 80} 81var lastMenuContainers = new Object(); 82function WTPToggleSubMenu(level, item) { 83 var p = item.parentElement; 84 var cont = p.nextSibling; 85 var lastContainer = null; 86 if (lastMenuContainers.hasOwnProperty("level" + level)) lastContainer = lastMenuContainers["level" + level]; 87 if (lastContainer != null && lastContainer != item) 88 WTPToggleSubMenu(level, lastContainer); 89 WTPtoggleE(cont); 90 lastMenuContainers["level" + level] = item != lastContainer ? item : null; 91 var img = item.getElementsByTagName("img"); 92 if (img != null && img.length > 0) { 93 if (lastContainer != null) 94 img[0].src = "/fileadmin/templates/images2/down.png"; 95 else img[0].src = "/fileadmin/templates/images2/right.png"; 96 } 97} 98function wtp_showuser() { 99 wtp_hideMenu(); 100 wtp_hideLang(); 101 WTPtoggle("wtp_user_content"); 102 wtpUserVisible = !wtpUserVisible; 103} 104function wtp_hideuser() { 105 if (wtpUserVisible) { 106 WTPtoggle("wtp_user_content"); 107 wtpUserVisible = false; 108 } 109} 110function wtp_showmenu() { 111 wtp_hideuser(); 112 wtp_hideLang(); 113 WTPtoggle("wtp_menu_content"); 114 wtpMenuVisible = !wtpMenuVisible; 115} 116function wtp_hideMenu() { 117 if (wtpMenuVisible) { 118 WTPtoggle("wtp_menu_content"); 119 wtpMenuVisible = false; 120 } 121} 122function wtp_showLang() { 123 wtp_hideMenu(); 124 wtp_hideuser(); 125 WTPtoggle("wtp_lang_content"); 126 wtpLangVisible = !wtpLangVisible; 127} 128function wtp_hideLang() { 129 if (wtpLangVisible) { 130 WTPtoggle("wtp_lang_content"); 131 wtpLangVisible = false; 132 } 133} 134function wtp_hideMenus() { 135 wtp_hideMenu(); 136 wtp_hideuser(); 137 wtp_hideLang(); 138}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.