<!--

function subs_pl(form) {

	ob = form;
	if (ob.email.value.indexOf('.') < 1) {
		window.alert('Adres email jest niepoprawny.');
		ob.email.focus();
		return false;
	}
	else
	if (ob.email.value.indexOf('@') < 1) {
		window.alert('Adres email jest niepoprawny.');
		ob.email.focus();
		return false;		
	}
	else
	if (ob.email.value.length < 6) {
		window.alert('Adres email jest niepoprawny.');
		ob.email.focus();
		return false;		
	}
	else {	
		ob.action = 'index.php?lang=pl&id=94&e='+ob.email.value;
		return true;			
	}

}

function subs_en(form) {

	ob = form;
	if (ob.email.value.indexOf('.') < 1) {
		window.alert('Invalid email address.');
		ob.email.focus();
		return false;
	}
	else
	if (ob.email.value.indexOf('@') < 1) {
		window.alert('Invalid email address.');
		ob.email.focus();
		return false;
	}
	else
	if (ob.email.value.length < 6) {
		window.alert('Invalid email address.');
		ob.email.focus();
		return false;
	}
	else {	
		ob.action = 'index.php?lang=en&id=94&e='+ob.email.value;
		return true;			
	}		

}

function sprawdz_rezygnacja_pl(form) {

	if ( form.email2.value == '' ) {
	
		window.alert('Nie podano adresu email.')
		form.email2.focus();
		return false;			

	} else return true;				
}

function sprawdz_rezygnacja_en(form) {

	if ( form.email2.value == '' ) {
	
		window.alert('Enter your email.')
		form.email2.focus();
		return false;			

	} 	
	else return true;					
}

function sprawdz_subskrypcja_en(form) {

	if ( form.email.value == '' ) {
	
		window.alert('Enter your email.')
		form.email.focus();
		return false;			

	} 	
	else return true;
}


function sprawdz_subskrypcja_pl(form) {

	if ( form.email.value == '' ) {
	
		window.alert('Nie podano adresu email.')
		form.email.focus();
		return false;			

	} else 
	{
	
		return true;
	}						
}

function sprawdz_twojeuwagi_pl(form) {

	if ( form.osoba.value == '' ) {
	
		window.alert('Nie podano danych osobowych.')
		form.osoba.focus();
		return false;			
	
	} else 
	if ( form.email.value == '' ) {
	
		window.alert('Nie podano adresu email.')
		form.email.focus();
		return false;			

	} else 
	if ( form.tekst.value == '' ) {
	
		window.alert('Nie podano tekstu uwagi.')
		form.tekst.focus();
		return false;			
	
	}	
	else {
	
		return true;
	}		
				

}

function sprawdz_twojeuwagi_en(form) {

	if ( form.osoba.value == '' ) {
	
		window.alert('Enter your name.')
		form.osoba.focus();
		return false;			
	
	} else 
	if ( form.email.value == '' ) {
	
		window.alert('Enter your email.')
		form.email.focus();
		return false;			

	} else 
	if ( form.tekst.value == '' ) {
	
		window.alert('Enter your comments.')
		form.tekst.focus();
		return false;			
	
	}	
	else {
	
		return true;
	}		
				

}

function sprawdz_akredytacja(form) {

	if ( (form.prasa.checked==false) && (form.radio.checked==false) && (form.internet.checked==false) && (form.fotograf.checked==false) && (form.tv.checked==false) && (form.agencja.checked==false) && (form.freelancer.checked==false) && (form.pr.checked==false) ) {
	
		window.alert('Nie wybrano formy akredytacji.')
		form.prasa.focus();
		return false;			
	
	}
	else 
	if ( form.osoba.value == '' ) {
	
		window.alert('Nie podano danych osobowych.')
		form.osoba.focus();
		return false;			
	
	}
	else 
	if ( form.tel.value == '' ) {
	
		window.alert('Nie podano telefonu kontaktowego.')
		form.tel.focus();
		return false;			
	
	}
	else 
	if ( form.email.value == '' ) {
	
		window.alert('Nie podano adresu email.')
		form.email.focus();
		return false;			
	
	}
	else 
	if ( (form.sprzet1.checked == false) && (form.sprzet2.checked == false) ) {

		window.alert('Nie wybrano opcji dot. sprzetu.')
		form.sprzet1.focus();
		return false;			
	
	}
	else 
	if ( (form.net1.checked == false) && (form.net2.checked == false) ) {

		window.alert('Nie wybrano opcji dot. internetu.')
		form.net1.focus();
		return false;			
	
	}
	else {
	
		return true;
	}		
				

}

function gray(cur,which){
if (which==0) {
	cur.filters.alpha.opacity=100;
}
else {
	cur.filters.alpha.opacity=50;
}

}

function druk() {
	
	window.focus();
	window.print();
}



function drukuj(param) {

	t = (screen.height-500)/2;
	w = (screen.width-588)/2;
	window.open ('drukuj.php?'+param,'','width=588,height=500,top='+t+',left='+w+',scrollbars=NO');
	
}


function galeria(jez, id,x,y) {

if ( y>(screen.height-100) ) { wys = screen.height-100; }
else wys = y+15;
if (jez == 0) jez2 ='pl';
else jez2 = 'en';

window.open ('zoom_gallery.php?lang='+jez2+'&id='+id+'&x='+x+'&y='+y,'','width='+(x+30)+',height='+wys+',top=10,left=30,scrollbars=YES');

}


function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->

//wyswietla zdjecie
function zdjecie(id,x,y,dzial) {
	x=x+20;
	y=y+30;
	t=(screen.height-y)/2;
	w=(screen.width-x)/2;
	window.open ('zoom.php?dzial='+dzial+'&id='+id,'','width='+x+',height='+y+',top='+t+',left='+w+',scrollbars=NO')
}





