
function majl(aleco){
domena="swiezyoddech.pl";
document.write("<a href=\"mailto:");
document.write(aleco+"@");
document.write(domena+"\">");
document.write(aleco+"@");
document.write(domena+"</a>");
}


var popup;
function pop(url,myWidth,myHeight ) { 
    myLeft = (screen.width-myWidth)/2;
    myTop = (screen.height-myHeight)/2;
    coords = 'scrollbars=0, resizable=0,left='+myLeft+',top='+myTop+',width='+myWidth+',height='+myHeight;
    if (popup) popup.close();
	popup=window.open(url,'popek',coords);
	}

function roll(){
	this.src = this.src.replace("_off","_on");
	}
function out(){
	this.src = this.src.replace("_on","_off");
	}


function roller(){
	
im=document.images;	
ladowane = new Array();
for (i=0; i<(im.length); i++) {
	if (im[i].src.search('_off.')!=-1){
		ladowane[i] = new Image;
		ladowane[i].src = im[i].src.replace("_off","_on");
		im[i].onmouseover = roll;
		im[i].onmouseout = out;
		}
	}
}

window.onload=roller;

sfHover = function() {
	var sfEls = document.getElementById("nav").getElementsByTagName("LI");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className+=" sfhover";
		}
		sfEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
		}
	}
}
if (window.attachEvent) window.attachEvent("onload", sfHover);

function validate(){
	f=document.forms[0];
	if (!f.reference.value || !f.start_date.value || !f.annual_quantity.value|| !f.product_codes.value || !f.description.value || !f.contact_name.value || !f.email.value ){
	
			alert("Please fill in fields arked with asterisk (*)");
			return false;
			}else{
				alert('Thank you for your inquiry');
				return true;
			}
	
}

   