WebAppDir="/SADB";function encode(a){return encodeURIComponent(a)}var agent=window.navigator.userAgent.toLowerCase();var isGecko=(agent.indexOf("gecko")!=-1);function keepAlive(a){if((typeof(keepAliveRunning)=="undefined")||(keepAliveRunning==null)){img=new Image();img.src=WebAppDir+"/LDAPProcessor?cmd=Empty";setTimeout("keepAliveRunning=null; keepAlive("+a+");",a*60000);keepAliveRunning=img}}var g_optionString="toolbar=1,location=1,menubar=1,directories=1,scrollbars=yes,resizable=1,status=1,hotkeys=1,dependent=0";function newWin(e,d,f,a){var c="";switch(f){case"":c=a;break;case"w800":c="width=790,height=500,"+g_optionString;break;case"w600":c="width=590,height=400,"+g_optionString;break;case"wXXX":c=g_optionString;break;default:alert("Fenstertyp unbekannt ("+f+")");break}d=d.replace(/\$/g,"_");var b=window.open(e,d,c);b.focus();return false}function autofocus(){var a;if(typeof(activeTab)!="undefined"){if(document.getElementById!=null){a=document.getElementById(activeTab)}else{a=document.all[i]}}active=true;for(i=0;i<document.forms.length;i++){if(typeof(document.forms[i].elements)!="undefined"){for(j=0;j<document.forms[i].elements.length;j++){if(typeof(a)!="undefined"){elem=document.forms[i].elements[j];active=false;while(!active&&(elem!=null)&&(typeof(elem)=="object")&&(typeof(elem.tagName)!="undefined")){tagname=elem.tagName.toUpperCase();if(tagname=="BODY"){elem=0}else{if(elem.id==a.id){active=true;elem=0}}if((typeof(elem)=="object")&&(typeof(elem.offsetParent)=="object")){elem=elem.parentNode}}}if(active&&!document.forms[i].elements[j].disabled&&(typeof(document.forms[i].elements[j].type)!="undefined")&&(document.forms[i].elements[j].type.indexOf("hidden")==-1)&&(document.forms[i].elements[j].type.indexOf("button")==-1)&&(document.forms[i].elements[j].type.indexOf("submit")==-1)&&(document.forms[i].elements[j].type.indexOf("cancel")==-1)){document.forms[i].elements[j].focus();return}}}}}function getQueryArgs(f){var b=new Object();var g=f.search.substring(1);var e=g.split("&");for(var c=0;c<e.length;c++){var h=e[c].indexOf("=");if(h==-1){continue}var a=e[c].substring(0,h);var d=e[c].substring(h+1);b[a]=d}return b}function addOption(a,c,b){if(agent.indexOf("gecko")==-1){newElem=a.document.createElement("OPTION");newElem.text=c;newElem.value=b;a.options.add(newElem,0)}else{a.options[a.length]=new Option(c,b,false,false)}if(-1==a.selectedIndex){a.options[0].selected=true}}function replaceOption(a,d,c,b){if(a.options.length>b){a.options[b].text=d;a.options[b].value=c;a.options[b].selected=true}else{addOption(a,d,c)}}function addSelection(a,c,b,d){for(i=0;i<a.options.length;i++){if(a.options[i].selected){if((typeof(b)=="undefined")||b){addOption(c,a.options[i].text,a.options[i].value)}if((typeof(d)=="undefined")||d){removeOption(a,i);i--}}}}function valueCompare(d,c){if(d>c){return 1}else{if(c>d){return -1}else{return 0}}}function sortOptionsByText(a,b){t=new Array();o=new Array();for(i=0;i<a.options.length;i++){t.push(a.options[i].text.toLowerCase());o[i]=new Object();o[i].text=a.options[i].text;o[i].value=a.options[i].value}t.sort();if(b==true){t.reverse()}for(i=a.options.length;i>=0;i--){removeOption(a,i)}for(i=0;i<t.length;i++){found=false;for(j=0;!found&&(j<o.length);j++){if(t[i]==o[j].text.toLowerCase()){addOption(a,o[j].text,o[j].value);found=true}}}}function removeOption(a,b){if(agent.indexOf("gecko")==-1){a.remove(b)}else{a.options[b]=null}}function moveOptionDown(a,b){if(b>0){tmpText=a.options[b-1].text;tmpValue=a.options[b-1].value;a.options[b-1].text=a.options[b].text;a.options[b-1].value=a.options[b].value;a.options[b].text=tmpText;a.options[b].value=tmpValue;for(i=0;i<a.options.length;i++){a.options[i].selected=false}a.options[b-1].selected=true}}function moveOptionUp(a,b){if(b<a.options.length-1){tmpText=a.options[b+1].text;tmpValue=a.options[b+1].value;a.options[b+1].text=a.options[b].text;a.options[b+1].value=a.options[b].value;a.options[b].text=tmpText;a.options[b].value=tmpValue;for(i=0;i<a.options.length;i++){a.options[i].selected=false}a.options[b+1].selected=true}}function initSelection(b,c,a){for(i=c.options.length;i>=0;i--){removeOption(c,i)}for(i=0;i<a.length;i++){for(j=0;j<b.options.length;j++){if(a[i]==b.options[j].value){addOption(c,b.options[j].text,b.options[j].value);removeOption(b,j);j=b.options.length}}}}function setAllCheckBoxes(e,c){if(null==e){return}var b=e.elements;if(!b){return}var d=b.length;if(!d){b.checked=c}else{for(var a=0;a<d;a++){if((b[a].type=="checkbox")&&!b[a].disabled){b[a].checked=c}}}}function getPosition(b){var c=b,d="",a=0,e=0;while((typeof(c)=="object")&&(c!=null)&&(typeof(c.tagName)!="undefined")){if(c.offsetTop>0){e+=c.offsetTop}if(c.offsetLeft>0){a+=c.offsetLeft}d=c.tagName.toUpperCase();if(d=="BODY"){c=0}if((typeof(c)=="object")&&(typeof(c.offsetParent)=="object")){c=c.offsetParent}}position=new Object();position.x=a;position.y=e;return position}var swappedText=null;function expandText(a,b){if(a.innerHTML){swappedText=a.innerHTML;a.innerHTML=b}}function collapseText(a,b){if(a.innerHTML){if(b){a.innerHTML=b}else{if(swappedText){a.innerHTML=swappedText}}}swappedText=null}function setTreeview(b,d){var a="/LDAPProcessor?cmd=Empty&nextpage=/WEB-INF/jsp/treeview.jsp";var c="&xid="+b+"#"+b;if(typeof top.frames.treeview!="undefined"){if(d){if(getQueryArgs(top.frames.treeview.location).xid==b){top.frames.treeview.location.reload()}else{top.frames.treeview.location.replace(WebAppDir+a+c)}}else{if(typeof top.frames.treeview.showObject!="undefined"){top.frames.treeview.showObject(top.frames.treeview,a,b)}else{top.frames.treeview.location.replace(WebAppDir+a+c)}}}}function showObject(a,b,d){var c=findObj(d);b=WebAppDir+b+"&xid="+d+"#"+d;if(c!=null){c.forceOpeningOfAncestorFolders();highlightObjLink(c);if(typeof c.isOpen!="undefined"){if(c.nChildren>0){if(!c.isOpen){clickOnNodeObj(c)}}else{a.location.replace(b)}}if(agent.indexOf("opera")==-1){location.hash=d}if(typeof window.pageYOffset!="undefined"){window.scrollTo(0,window.pageYOffset)}}else{a.location.replace(b)}}var submitListeners=new Array();function sf(a,c,d){if((null==c)||(c=="")){return false}var b="";if(c=="Delete"){b="Möchten Sie den Eintrag\r\n"+document.forms["obj_"+a].dn.value.replace(/\+/g," ")+"\r\nwirklich löschen?"}if(c=="Rename"){b="Der Eintrag\r\n"+document.forms["obj_"+a].dn.value.replace(/\+/g," ")+"\r\nwird wie folgt geändert:\r\n"+document.forms["obj_"+a].newDN.value.replace(/\+/g," ")+"\r\nDiese Aktion kann einige Zeit in Anspruch nehmen. Möchten Sie fortfahren?"}if(b!=""){if(!window.confirm(b)){return}}document.forms["obj_"+a].cmd.value=c;if(typeof d!="undefined"){document.forms["obj_"+a].action=document.forms["obj_"+a].action+"?"+d}for(i=0;i<submitListeners.length;i++){submitListeners[i]()}document.forms["obj_"+a].submit()}function submitOnReturn(a){if(typeof(a)!="undefined"){if(13==a.which){if(null!=document.forms.Logon){document.forms.Logon.submit()}else{if(typeof(window.event)!="undefined"){if(13==window.event.keyCode){if(null!=document.forms.Logon){document.forms.Logon.submit()}}}}}}}function selectFromTree(f,a,d,g,c,e,h,b){if(typeof(e)=="-1"){e="32767"}url=WebAppDir+"/LDAPProcessor?cmd=Empty&nextpage=/WEB-INF/jsp/selectfromtree.jsp";url+="&formname="+f.name;url+="&input="+a.id;url+="&inputvalues="+encode(a.value);url+="&display="+d.id;url+="&attribute="+g;url+="&basedn="+c;url+="&maxselect="+e;url+="&dnsyntax="+h;if(b==true){url+="&authpool=true"}else{url+="&authpool=false"}newWin(url,f.name+"_treeselect","","height=570,width=480")}function selectBySearch(e,a,f,c,d,g,b){if(typeof(d)=="-1"){d="32767"}url=WebAppDir+"/LDAPProcessor?cmd=Empty&nextpage=/WEB-INF/jsp/selectbysearch.jsp";url+="&formname="+e.name;url+="&input="+a.id;url+="&inputvalues="+encode(a.value);url+="&attribute="+f;url+="&basedn="+c;url+="&maxselect="+d;url+="&dnsyntax="+g;if(b==true){url+="&authpool=true"}else{url+="&authpool=false"}newWin(url,e.name+"_treeselect","","height=570,width=480")}function selectOrSearchFromTree(f,a,d,g,c,e,h,b){if(typeof(e)=="-1"){e="32767"}url=WebAppDir+"/LDAPProcessor?cmd=Empty&nextpage=/WEB-INF/jsp/select_or_searchfromtree.jsp";url+="&formname="+f.name;url+="&input="+a.id;url+="&inputvalues="+encode(a.value);url+="&display="+d.id;url+="&attribute="+g;url+="&basedn="+c;url+="&maxselect="+e;url+="&dnsyntax="+h;if(b==true){url+="&authpool=true"}else{url+="&authpool=false"}newWin(url,f.name+"_treeselect","","height=730,width=480,resizable=yes")}function selectAddressBySearch(e,a,f,c,d,g,b){if(typeof(d)=="-1"){d="32767"}url=WebAppDir+"/LDAPProcessor?cmd=Empty&nextpage=/WEB-INF/jsp/sadb/selectaddressbysearch.jsp";url+="&formname="+e.name;url+="&input="+a.id;url+="&inputvalues="+encode(a.value);url+="&attribute="+f;url+="&basedn=cn=addresses";url+="&maxselect="+d;url+="&dnsyntax="+g;if(b==true){url+="&authpool=true"}else{url+="&authpool=false"}newWin(url,e.name+"_treeselect","","height=570,width=480")}function showUserStatus(){newWin=window.open(WebAppDir+"/LDAPProcessor?cmd=Empty&nextpage=/WEB-INF/jsp/usermgmt/userstatus.jsp","UserStatus","height=550,width=480,scrollbars");newWin.focus()}function destroyFrameset(){if(top.frames.length>1){top.location.href=WebAppDir}}var ACTIVE_COLOR="#EEEEEE";var INACTIVE_COLOR="#CCCCCC";var ACTIVE_BGCOLOR="#5353FF";var INACTIVE_BGCOLOR="#000000";var MOUSEOVER_COLOR="";var MOUSEOVER_BGCOLOR="";var TAB_SPACING=6;var TAB_PADDING=4;var TAB_WIDTH="100";var TAB_HEIGHT="20";var BORDER_WIDTH=1;var BORDER_STYLE="solid";var CONTENT_BGCOLOR="#CCCCCC";var CONTENT_WIDTH="";var CONTENT_HEIGHT="";var tabTop;var tabLeft;var activeTab;var tabItems=new Array();function createTabs(){var a="<DIV id=tabs><TABLE border=0 cellspacing="+TAB_SPACING+" cellpadding="+TAB_PADDING+"><TR>";for(i=0;i<tabItems.length;i++){a+="<TD id=t"+(1000+i)+" width="+TAB_WIDTH+" height="+TAB_HEIGHT+" align=middle onclick='javascript:activateTab("+i+");' onmouseover='flipColors("+i+")' onmouseout='resetColors("+i+")'>";a+="<A ID=t"+(1100+i)+" HREF='javascript:activateTab("+i+");'>";a+=tabItems[i];a+="</A>";a+="</TD>"}a+="</TR></TABLE></DIV><div id=taboffset></div>";document.write(a)}function flipColors(c){if(c!=activeTab){var a;var b;if(document.getElementById!=null){a=document.getElementById("t"+(1000+c));b=document.getElementById("t"+(1100+c))}else{if(document.all[i]!=undefined){a=document.all["t"+(1000+c)];b=document.all["t"+(1100+c)]}}b.style.color=MOUSEOVER_COLOR;a.style.backgroundColor=MOUSEOVER_BGCOLOR}}function resetColors(c){if(c!=activeTab){var a;var b;if(document.getElementById!=null){a=document.getElementById("t"+(1000+c));b=document.getElementById("t"+(1100+c))}else{if(document.all[i]!=undefined){a=document.all["t"+(1000+c)];b=document.all["t"+(1100+c)]}}b.style.color=INACTIVE_COLOR;a.style.backgroundColor=INACTIVE_BGCOLOR}}function initTabs(){var a;if(typeof(tabTop)=="undefined"){tabTop=0}else{tabTop=-2}if(document.getElementById!=null){a=getPosition(document.getElementById("taboffset"))}else{a=getPostion(document.all.taboffset)}tabTop+=a.y-TAB_SPACING+(TAB_PADDING/2)-BORDER_WIDTH;if(tabItems.length==1){tabTop-=1}tabLeft=a.x+TAB_SPACING;if(MOUSEOVER_COLOR==""){MOUSEOVER_COLOR=INACTIVE_BGCOLOR}if(MOUSEOVER_BGCOLOR==""){MOUSEOVER_BGCOLOR=INACTIVE_COLOR}if(CONTENT_WIDTH==""){CONTENT_WIDTH=(tabItems.length*TAB_WIDTH)+((tabItems.length-1)*TAB_SPACING)}if(null==activeTab){activeTab=0}if(tabItems.length>0){activateTab(activeTab)}}function activateTab(b,a){var d=null;var c=null;if(document.getElementById!=null){for(i=0;i<tabItems.length;i++){document.getElementById("t"+(1000+i)).style.backgroundColor=INACTIVE_BGCOLOR;document.getElementById("t"+(1100+i)).style.color=INACTIVE_COLOR;document.getElementById("t"+(1000+i)).style.borderColor=INACTIVE_COLOR;document.getElementById("t"+(1000+i)).style.borderStyle=BORDER_STYLE;document.getElementById("t"+(1000+i)).style.borderWidth=BORDER_WIDTH;document.getElementById("t"+(1000+i)).style.borderBottomColor=ACTIVE_COLOR}document.getElementById("t"+(1000+b)).style.backgroundColor=ACTIVE_BGCOLOR;document.getElementById("t"+(1100+b)).style.color=ACTIVE_COLOR;document.getElementById("t"+(1000+b)).style.borderColor=ACTIVE_COLOR;document.getElementById("t"+(1000+b)).style.borderStyle=BORDER_STYLE;document.getElementById("t"+(1000+b)).style.borderWidth=BORDER_WIDTH;document.getElementById("t"+(1000+b)).style.borderBottomStyle="none";d=document.getElementById(b)}else{if(document.all){for(i=0;i<tabItems.length;i++){document.all["t"+(1000+i)].style.backgroundColor=INACTIVE_BGCOLOR;document.all["t"+(1100+i)].style.color=INACTIVE_COLOR;document.all["t"+(1000+i)].style.borderColor=INACTIVE_BGCOLOR;document.all["t"+(1000+i)].style.borderStyle=BORDER_STYLE;document.all["t"+(1000+i)].style.borderWidth=BORDER_WIDTH;document.all["t"+(1000+i)].style.borderBottomColor=ACTIVE_COLOR}document.all["t"+(1000+b)].style.backgroundColor=ACTIVE_BGCOLOR;document.all["t"+(1100+b)].style.color=ACTIVE_COLOR;document.all["t"+(1000+b)].style.borderColor=ACTIVE_COLOR;document.all["t"+(1000+b)].style.borderStyle=BORDER_STYLE;document.all["t"+(1000+b)].style.borderWidth=BORDER_WIDTH;document.all["t"+(1000+b)].style.borderBottomStyle="none";d=document.all[b]}}if(d!=null){activeTab=b;d.style.position="absolute";d.style.top=tabTop;d.style.left=tabLeft;d.style.width=CONTENT_WIDTH;if(isGecko){d.style.minHeight=CONTENT_HEIGHT}else{d.style.height=CONTENT_HEIGHT}d.style.backgroundColor=CONTENT_BGCOLOR;d.style.borderColor=ACTIVE_COLOR;d.style.borderStyle=BORDER_STYLE;d.style.borderWidth=BORDER_WIDTH;expand(b);if(document.getElementById!=null){c=document.getElementById("tabs")}else{c=document.all.tabs}c.style.position="relative";c.style.zIndex=1;if(typeof(a)=="undefined"){autofocus()}else{if(document.getElementById!=null){field=document.getElementById(a)}else{field=document.all[a]}if(null!=field){field.focus()}else{autofocus()}}}}function expand(c){var a=0;if(document.getElementById!=null){while(document.getElementById(a)!=undefined){collapse(a++)}}else{while(document.all[a]!=undefined){collapse(a++)}}var b;if(document.getElementById!=null){b=document.getElementById(c)}else{if(document.all[a]!=undefined){b=document.all[a]}}if(typeof(b)!="undefined"){b.style.visibility="visible";b.style.padding="3px";b.style.overflow="auto";if(isGecko){b.style.position="fixed";b.style.position="absolute"}}}function collapse(a){if((document.getElementById!=null)&&(document.getElementById(a).tagName.toUpperCase()=="DIV")){document.getElementById(a).style.visibility="hidden"}else{if(document.all&&(document.all[a].tagName.toUpperCase()=="DIV")){document.all[a].style.visibility="hidden"}}}function showMenu(f,b,c){if(!document.onclick){document.onclick=showMenu}var e=document.getElementById(f);if(!b){b="7em"}if(!c){c="0"}for(var a=0;a<=10;a++){if(document.getElementById("smenu"+a)){document.getElementById("smenu"+a).style.padding="0";document.getElementById("smenu"+a).style.width=b;document.getElementById("smenu"+a).style.display="block";document.getElementById("smenu"+a).style.overflow="hidden";document.getElementById("smenu"+a).style.visibility="hidden";document.getElementById("smenu"+a).style.visibility="hidden"}}if(e){e.style.padding=c;if(isGecko){e.style.width=null;e.style.minWidth=b}else{e.style.width=b}e.style.overflow="visible";e.style.visibility="visible";if(isGecko){document.body.blur()}else{e.focus()}}else{for(var a=0;a<=10;a++){if(document.getElementById("smenu"+a)){document.getElementById("smenu"+a).style.display="none"}}}}Object.extend(Event,{_domReady:function(){if(arguments.callee.done){return}arguments.callee.done=true;if(this._timer){clearInterval(this._timer)}this._readyCallbacks.each(function(a){a()});this._readyCallbacks=null},onDOMReady:function(f){if(!this._readyCallbacks){var domReady=this._domReady.bind(this);if(document.addEventListener){document.addEventListener("DOMContentLoaded",domReady,false);
/*@cc_on @*/
/*@if (@_win32)
                    document.write("<script id=__ie_onload defer src=javascript:void(0)><\/script>");
                    document.getElementById("__ie_onload").onreadystatechange = function() {
                        if (this.readyState == "complete") domReady();
                    };
                /*@end @*/
}if(/WebKit/i.test(navigator.userAgent)){this._timer=setInterval(function(){if(/loaded|complete/.test(document.readyState)){domReady()}},10)}Event.observe(window,"load",domReady);Event._readyCallbacks=[]}Event._readyCallbacks.push(f)}});MultiRow=Class.create();MultiRow.prototype={initialize:function(a){this.master=a;this.rowElem=null;this.last=null;this.next=null},addRow:function(b,a){if(b){if(b.element){b=b.element()._row.rowElem}var c=new MultiRow(this.master);c.rowElem=new Element("div");c.rowElem.innerHTML=this.master.innerHTML;b.insert({after:$(c.rowElem)});if(this.last!=null){c.last=this;c.next=this.next;c.last.next=c;c.next.last=c}else{c.next=c.last=c;this.first=c;c.anchor=this}if(a){for(i=0;i<a.length;i++){if(a[i].className&&a[i].value){c.rowElem.select("."+a[i].className).each(function(f){var d=f.tagName.toUpperCase();if(d=="INPUT"){f.value=a[i].value}else{if(d=="SELECT"){var e=false;for(j=0;!e&&(j<f.options.length);j++){if(f.options[j].value==a[i].value){e=f.options[j].selected=true}}}}})}}}return c}},getHTMLRow:function(){return this.rowElem},addControls:function(a){var d=new Element("span");d.setStyle("display","inline");var c=new Element("input");c._row=this;c.type="button";c.addClassName("add_row");c.value="+";c.observe("click",(function(){var e=this.addRow(this.rowElem);if(a){e.addControls(a)}}).bind(this));var b=new Element("input");b.type="button";b.addClassName("remove_row");b.value="-";b.observe("click",(function(){this.removeRow()}).bind(this));d.insert(c);d.insert(b);this.rowElem.insert(d)},removeRow:function(){if(this.last!=this){this.rowElem.remove();this.next.last=this.last;this.last.next=this.next;if(this.anchor){this.anchor.first=this.next;this.next.anchor=this.anchor}}},getValues:function(b){var d=null;var a=new Array();if(this.first){d=this.first}else{d=this;while(!d.anchor){d=d.next}}var c=d;do{c.rowElem.select("."+b).each(function(f){var e=f.tagName.toUpperCase();if(e=="INPUT"){a.push(f.value)}else{if(e=="SELECT"){a.push(f.options[f.selectedIndex].value)}}});c=c.next}while(d!=c);return a},getValuesAsString:function(c){var a=this.getValues(c);var b="";for(i=0;i<a.length;i++){if(i>0){b+="\n"}b+=a[i]}return b}};