function on(element1,content1,tdNr,mh1,yr1){
	x1=mh1.charAt(0);
	if(mh1<10 && x1!=0){mh2=0+mh1;}else{mh2=mh1;}
	el1=document.getElementById(element1);
	el1.innerHTML='<div style="text-align:left;padding-top:1px;padding-right:1px;padding-bottom:1px;padding-left:3px;border:solid; border-color:#BFA260; border-width:1px;background-color:#FFF7E6;color:#000000;"><table style="font-size:12px;" width="168"><tr><td colspan=2 align=right>'+tdNr+'.'+mh2+'.'+yr1+'</td></tr>'+content1+'</table></div>';
	el1.className="visible";
	table1=document.getElementById("kalendarz");
	for($ia=1;$ia<table1.rows.length;$ia++)
	{
		for($ib=0;$ib<table1.rows.item($ia).cells.length;$ib++)
		{
			table1.rows.item($ia).cells.item($ib).style.borderColor="#F5F5F5";
		}
	}
	tdId='tdCal'+tdNr;
	td1=document.getElementById(tdId);
	td1.style.borderColor="#BFA260";
}
function displayWindow(url) {
	var Win = window.open(url,"displayWindow",'width=700'+',height=500'+ ',resizable=1,scrollbars=yes,menubar=no' );
}
function divVis(divID)
{	
	divN=document.getElementById(divID);//div z opisem
	for(i=0;i<divN.parentNode.childNodes.length;i++)//ukrycie wszystkich DIV
	{
	 if(divN.parentNode.childNodes.item(i).nodeName=="DIV"){divN.parentNode.childNodes.item(i).className='hidden';}
	}
	for(i=0;i<divN.parentNode.childNodes.length;i++)//ukrycie wszystkich SPAN
	{
	 if(divN.parentNode.childNodes.item(i).nodeName=="SPAN"){divN.parentNode.childNodes.item(i).className='hidden';divN.parentNode.childNodes.item(i).nextSibling.className='teacher';}
	}
	if(divN.className=='hidden'){divN.className='visible';divN.previousSibling.className='teacherBg';}//DIV
	else{divN.className='hidden';divN.previousSibling.className='teacher';}
	divN.previousSibling.previousSibling.className='visibleS';//SPAN
}
function mail1(login1, server1)
{
 this.l1 = login1;
 this.s1 = server1;
 this.w1 = written1;
}
function written1()
{
 with (this)
 {
  m1="mail";
  m2="to:";
  at=String.fromCharCode(64);
  document.write('<a href=\"'+m1+m2+l1+at+s1+'\">'+l1+at+s1+'<\/a>');
 }
}
borski=new mail1("tomaszborski","o2.pl");
czermak=new mail1("czermak","ks.k.pl");
gromolak=new mail1("waldemar","gromolak.com");
adamowski=new mail1("jerzy.adamowski","op.pl");
lykowski=new mail1("plykowski","wp.pl");
szkolaOLD=new mail1("psm2wroclaw","post.pl");
szkolaNEW=new mail1("sekretariat","psmpodwale.pl");
cea=new mail1("sekr","cea.art.pl");
lowiecka=new mail1("sekretariat","lowiecka.wroclaw.pl");
rada=new mail1("rada.szkoly","psmpodwale.pl");
radarodz=new mail1("rada.rodzicow","psmpodwale.pl");
samo=new mail1("samorzad","psmpodwale.pl");
firek=new mail1("dlafirek","poczta.onet.pl");
pastuszka=new mail1("tubamusic","wp.pl");
gembara=new mail1("1979arek","wp.pl");
rusina=new mail1("olgarusina","poczta.onet.pl");


function fWin(vImgUrl, vImgWidth,  vImgHeight){
   var vWindowWidth = vImgWidth * 1.0 + 10;
   var vWindowHeight =  vImgHeight * 1.0 + 10;
   var vWindowLeft = ( screen.width / 2 ) - ( vWindowWidth / 2);
   var vWindowTop = ( screen.height / 2 ) - ( vWindowHeight / 2);
   var vWindow = window.open("", "", "toolbar=no, menubar=no, location=no, personalbar=no, status=no, resizable=no, scrollbars=no, copyhistory=no, width="+vWindowWidth+", height="+vWindowHeight+", top="+vWindowTop+", left="+vWindowLeft);
   vWindow.document.write('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">\n'+
   '<html>\n'+
   '\t<head>\n'+
   '\t\t<title> </title>\n'+
   '\t\t<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">\n'+
   '\t</head>\n'+
   '\t<body style="text-align:center; margin:0px; padding:5px; overflow:auto;background-color:#000000;">\n'+
   '\t\t<img src="'+vImgUrl+'" onclick="javascript:window.close();">\n'+
   '\t</body>\n'+
   '</html>\n');   
} 
function onoff(divIDX)
{	
	divX=document.getElementById(divIDX);//div z opisem
	if(divX.style.display == 'none' || divX.style.display == ''){divX.style.display='block'}
	else{divX.style.display='none'}
}
