NS4 = (document.layers) ; IE4 = (document.all) ; mac=((IE4)&&(navigator.appVersion.indexOf ("Mac")!=-1)); DOM=document.documentElement&&!NS4&&!IE4; mswnd=(navigator.appVersion.indexOf("Windows")!=-1||navigator.appVersion.indexOf("WinNT")!=-1); if(IE4) { av=navigator.appVersion; avi=av.indexOf("MSIE"); if (avi==-1) version = parseInt(av); else { var version = av.substring(avi+4, avi+8); version = parseInt(version); } } var menuLibDef = false; var JS_detect_flash=0; //if(navigator.plugins["Shockwave Flash"]) JS_detect_flash = 1; function load(key, name, value, target) { document.epus.elements.key.value = key; if(name) document.epus.elements[name].value = value; document.epus.target = target; document.epus.submit(); } function printer(url) { var x = parseInt(window.screen.availWidth/10); var y = parseInt(window.screen.availHeight/10); w = parseInt(window.screen.availWidth/1.3); h = parseInt(window.screen.availHeight/1.4); win = window.open(url, 'print', 'toolbar=yes,scrollbars=yes,status=no,resizable=yes,height='+h+',width='+w+",left="+x+",top="+y+",screenX="+x+",screenY="+y); if(win) { win.focus(); //if(win.print) win.print(); } } function view(url, w, h) { var x = parseInt(window.screen.availWidth/5); var y = parseInt(window.screen.availHeight/5); w = w + 34; h = h + 33; win = window.open(url, 'win', 'scrollbars=yes,status=yes,resizable=yes,height='+h+',width='+w+",left="+x+",top="+y+",screenX="+x+",screenY="+y); if(win) { win.resizeTo(w, h); win.focus(); } } function getObject(object) { var dom = window.document; var result = null; if(dom) { if(dom.getElementById && dom.getElementById(object) != null) { result = dom.getElementById(object); } else if(dom.layers) { result = dom.layers[object]; } else if (dom.all) { if(dom.all[object]) result = dom.all[object]; } } return result; } function setHTML(object, html) { var source = getObject(object); if(source == null) return false; source.innerHTML = html; return true; } function setVisible(object) { var source = getObject(object); if(source == null) return false; if(source.style) source.style.visibility = 'visible'; if(source.visibility) source.visibility = 'show'; return true; } function setHidden(object) { var source = getObject(object); if(source == null) return false; if(source.style) source.style.visibility = 'hidden'; if(source.visibility) source.visibility = 'hide'; return true; } function setDisplay(object, value) { var source = getObject(object); if(source == null) return false; if(source.style) source.style.display = value; return true; } function sendLogin(form) { form.user_password.value = calcMD5(form.input_password.value); form.input_password.value = ""; return true; } function showCatalogueSearch(id) { id = parseInt(id); setDisplay('form'+id, 'block'); setDisplay('hide'+id, 'inline'); setDisplay('show'+id, 'none'); return true; } function hideCatalogueSearch(id) { id = parseInt(id); setDisplay('form'+id, 'none'); setDisplay('hide'+id, 'none'); setDisplay('show'+id, 'inline'); return true; } function popMenu(url) { url = unescape(url); w = 800 + 34; h = 600 + 33; win = window.open(url, 'popMenu', 'scrollbars=yes,status=yes,resizable=yes,height='+h+',width='+w); win.focus(); } function setPage(url) { window.location.href = url; } function confirmRemove(action) { var result = window.confirm('Odstranit poloÅūku?'); if(result) { setPage(action); } } function displayIn(from , to, className) { var ofrom = getObject(from); var oto = getObject(to); var html = ""; if(ofrom) { html = ofrom.innerHTML; } if(oto) { oto.innerHTML = html; oto.className = className; oto.style.display = "block"; } }