var show = new Array();
show['products']=0;
show['about']=0;
show['news']=0;
show['retailers']=0;

function showMenu(object) {
	hideAll();
	show[object]=1;
 document.getElementById("dd_"+object).style.visibility="visible";
}

function hideMenu(object) {
	if (show[object]==0) {
  document.getElementById("dd_"+object).style.visibility="hidden";
	}
}

function preHide(object) {
 show[object]=0;
 setTimeout("hideMenu('"+object+"')",1000);
}

function hideAll() {
	show['products']=0;
	show['about']=0;
	show['news']=0;
	show['retailers']=0;
 hideMenu('products');
 hideMenu('about');
 hideMenu('news');
 //hideMenu('retailers');
}

function checkEmail(email) {
 if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(email.toLowerCase())) {
  return true;
 } else {
  return false;
 }
}

function isInt(myNum) {
 // get the modulus: if it's 0, then it's an integer
  var myMod = myNum % 1;
 if (myMod == 0) {
  return true;
 } else {
  return false;
 }
}

function changeBig(num,prod) {
 document.getElementById('big').style.backgroundImage='url(img/products/'+prod+'-'+num+'-lg.jpg)';
 return false;
}
