function newImage(arg) {
if (document.images) {
rslt = new Image();
rslt.src = arg;
return rslt;
}
}

function changeImages() {
if (document.images && (preloadFlag == true)) {
for (var i=0; i<changeImages.arguments.length; i+=2) {
document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
}
}
}

var preloadFlag = false;
function preloadImages() {
if (document.images) {
n_home_o = newImage("images/n_home_o.gif");
n_about_o = newImage("images/n_about_o.gif");
n_program_o = newImage("images/n_program_o.gif");
n_hours_o = newImage("images/n_hours_o.gif");
n_contact_o = newImage("images/n_contact_o.gif");
n_espanol_o = newImage("images/n_espanol_o.gif");
preloadFlag = true;
}
}







function Validate(theForm) {

  if (theForm.name.value.length =="")
  {
    alert("Please enter a value for the \"Name\"\ and \"Email\"\ field.");
    theForm.name.focus();
    return (false);
  }
  
  if (theForm.email.value.length =="")
  {
    alert("Please enter a value for the \"Name\"\ and \"Email\"\ field.");
    theForm.email.focus();
    return (false);
  }   
}






function NewWindow(file, w, h){
window.open(file,"NewWindow","toolbar=no,directories=no,resizable=yes,scrollbars=no,location=no,menubar=no,width="+w+",height="+h);
}


function NewWindowTesti(file, w, h){

window.open(file,"NewWindowTesti","toolbar=no,directories=no,resizable=no,scrollbars=no,location=no,menubar=no,width="+w+",height="+h);
}








//hide pop-overs 

ns4 = document.layers
ie4 = document.all 
nn6 = document.getElementById && !document.all 

function hideObject(id) {
   if (ns4) {
      document.getElementById(id).visibility = "hide";
   }
   else if (ie4) {
      document.all[id].style.visibility = "hidden";
   }
   else if (nn6) {
      document.getElementById(id).style.visibility = "hidden";
   }
}

// Show/Hide functions for pointer objects

function showObject(id) {
   if (ns4) {
      document.getElementById(id).visibility = "show";
   }
   else if (ie4) {
      document.all[id].style.visibility = "visible";
   }
   else if (nn6) {
      document.getElementById(id).style.visibility = "visible";
   }
}


