var global_akt_sub_div=""; function init() { // var url="http://www.alltagsservice-neuhausen.de/epublix1/gw?s=asnh&f=jstoc&doc="+global_site_name+":root&action=start&sl=0&depth=10&level=10"; // global_jstock_xml = loadXml(url) var anker_array = new Array(); anker_array = anker.split(","); if (anker_array.length > 0 && anker_array[0].length > 0) { scroll(anker_array[0]); } if (anker_array.length > 1) { // Auch docid ´┐Żebergeben show_docnext(anker_array[1]); } } function scroll(anker) { if ( anker != "") { if(anker.length > 3 && anker.substring(0,3)=="&p=") anker = anker.substring(3); var link_nodes = document.anchors; if (link_nodes.length) { for (var i=0 ; i < link_nodes.length ; i++) { if ( link_nodes[i].getAttribute("name") == anker) { scrolltop(link_nodes[i],"content_div",0); // scrollIntoView("true"); } } } } } function fmouseout(e) { if(!e) { e = window.event; } var reltg = (e.relatedTarget) ? e.relatedTarget : e.toElement; while (reltg.tagName != "BODY") { if (reltg.id == this.id) { return; } reltg = reltg.parentNode; } // Jetzt sind wir im mouseout in wlechen var id = (e.srcElement) ? e.srcElement.id : e.currentTarget.id; // alert("rel "+reltg.id + " src"+id) if (id) { document.getElementById(id).style.display=("none"); } } function hidesubdiv() { if (global_akt_sub_div) { document.getElementById(global_akt_sub_div).style.display="none"; } } function checksubdoc(docid,divid) { var subdiv = document.getElementById(divid); hidesubdiv(); if (!subdiv) { var url="http://www.alltagsservice-neuhausen.de/epublix1/gw?s=asnh&f=jstoc&doc="+docid+"&action=expand&depth=10&sl=0&level=5"; var jstoc_expand = loadXml(url); var nodes = new Array(); nodes = XMLgetElementsByAtt(jstoc_expand,docid,"nid"); if (nodes.length) { subdiv = show_subtoc(nodes,divid) } } if (subdiv) { global_akt_sub_div = divid; subdiv.style.display="block"; } } function show_subtoc(nodes,divid) { var innerhtml = ""; var subdiv = document.getElementById(divid); if (!subdiv) { x = document.createElement("div"); x.setAttribute("id",divid); if (dsgle_site=="document") { document.getElementById("nav_div").appendChild(x); } else { document.getElementById("nav_main_div").appendChild(x); } subdiv = document.getElementById(divid); subdiv.onmouseout = fmouseout; // innerhtml = "
"; innerhtml = "
"; for ( var i=0; i < nodes.length; i++){ if (i) { innerhtml+="
"; } innerhtml+=""; innerhtml += nodes[i].getAttribute("text"); innerhtml += ""; } innerhtml += ""; subdiv.innerHTML = innerhtml; } global_akt_sub_div = divid; subdiv.style.display="block"; return subdiv; } function show_docnext(docid) { var url="http://www.alltagsservice-neuhausen.de/epublix1/gw?s=asnh&f=jstoc&doc="+docid+"&action=expand&depth=10&sl=0&level=5"; var jstoc_expand = loadXml(url); var nodes = new Array(); nodes = XMLgetElementsByAtt(jstoc_expand,"3","level"); if (nodes.length) { url="http://www.alltagsservice-neuhausen.de/epublix1/gw?s=asnh&f=document&id="+nodes[0].getAttribute("nid")+"&t=leereshtm.htm" loadTemplate(url,"","","content_top",""); } if (nodes.length>1) { url="http://www.alltagsservice-neuhausen.de/epublix1/gw?s=asnh&f=document&id="+nodes[1].getAttribute("nid")+"&t=leereshtm.htm" loadTemplate(url,"","","content_next",""); } } function displayTemplate(fenster_id,funktion) { var docainh = document.getElementById(fenster_id); var doc = docainh.getAttribute("doctype"); var temp = document.getElementById(doc); if (temp) { temp.appendChild(docainh); docainh.style.display="block"; temp.style.display="block"; } }