var containers=new Array(); var visibleContainer=null; var reg; var reg2; var link1='o_nas'; var link2=''; var prawa; var body; function init_links() { prawa=document.getElementById('right'); body=document.getElementById('body'); var as=document.getElementsByTagName('a'); var m=location.href.match(/^http:\/\/.[^\/]+\/(.[^\/]*)\/?(.*)/); if(m) { link1=m[1].replace(/\.html$/,''); link2=m[2].replace(/\.html$/,''); } reg=new RegExp("^https://eko-dom.info/"+link1); reg2=new RegExp("^https://eko-dom.info/"+link1+"/"+link2); for(var i=0; i0) { as[i].className='actual'; } else as[i].className=as[i].oldClassName; as[i].linkID=as[i].href.replace(/^http:\/\/.[^\/]+\/(.*?)(\.html)?$/,'$1').replace(/\//g,'-').replace(/%/g,'_'); as[i].onclick=function(e) { if(e==undefined) e=window.event; if((e.preventDefault)&&(e.cancellable)) e.preventDefault(); var as=document.getElementsByTagName('a'); for(var i=0; i'; body.appendChild(div); if(prawa) { var vc=prawa.getElementsByTagName('div'); if(vc.length>0) { visibleContainer=vc[0]; visibleContainer.myheight=visibleContainer.offsetHeight; } } } if (window.attachEvent) window.attachEvent('onload', init_links); if (window.addEventListener) window.addEventListener('load', init_links,false); function createHTTPreq() { var opisik=false; try { opisik = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { opisik = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { opisik = false; } } if (!opisik && typeof XMLHttpRequest!='undefined') { try { opisik = new XMLHttpRequest(); } catch (e) { opisik=false; } } if (!opisik && window.createRequest) { try { opisik = window.createRequest(); } catch (e) { opisik=false; } } return opisik; } function myhttreq(requestFile,sr,send) { if(send!=null) { sr.open("POST", requestFile,true); sr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded; charset=UTF-8"); sr.send(send); } else { sr.open("GET", requestFile,true); sr.send(null); } } function getRightContent(url,myid) { var sendcom=createHTTPreq(); if(sendcom) { sendcom.onreadystatechange=function() { if(sendcom.readyState == 4 && sendcom.status == 200) { if(sendcom.responseText != null) { var div=document.createElement('div'); div.id=myid; div.innerHTML=sendcom.responseText; div.style.display="none"; div.myheight=div.offsetHeight; prawa.appendChild(div); new Effect.Fade('WaitImgContainer', { duration: 0.5, queue : { position: 'end', scope: 'showhide' } }); showContainer(myid); } else { } } else if (sendcom.readyState == 4 && sendcom.status != 200) { } else { } } url=url.replace(/^(http:\/\/.[^\/]+\/)/,'$1getRightContent/').replace(/\.html$/,''); myhttreq(url,sendcom,null); } } function showContainer(id) { var seek=document.getElementById(id); visibleContainer=seek; new Effect.BlindDown(id, { duration: 0.5, queue : { position: 'end', scope: 'showhide' } }); // new Effect.Morph('right',{ style: 'height: 200px;',duration: 0.5, queue : { position: 'end', scope: 'showhide' } }); } function myShow(url,id) { var seek=document.getElementById(id); var wait=document.getElementById('WaitImgContainer'); if(prawa) { wait.style.top=prawa.offsetTop+'px'; wait.style.left=prawa.offsetLeft+'px'; } if(!seek) { new Effect.BlindUp(visibleContainer.id, { duration: 0.5, queue : { position: 'end', scope: 'showhide' } }); new Effect.Appear('WaitImgContainer', { duration: 0.5, queue : { position: 'end', scope: 'showhide' } }); getRightContent(url,id); } else { if(visibleContainer.id!=id) { new Effect.BlindUp(visibleContainer.id, { duration: 0.5, queue : { position: 'end', scope: 'showhide' } }); showContainer(id) } } }