


function preloadImages()  {
  var d = document;
  if (d.images)  {
    d.ifha_pre = new Array();
    for (i = 0; i < 8; i++)  {
      d.ifha_pre[i] = new Image();
    }
    d.ifha_pre[0].src = '/img/ifha_nav_bg_home.png';
    d.ifha_pre[1].src = '/img/ifha_nav_bg_about.png';
    d.ifha_pre[2].src = '/img/ifha_nav_bg_pract.png';
    d.ifha_pre[3].src = '/img/ifha_nav_bg_serv.png';
    d.ifha_pre[4].src = '/img/ifha_nav_bg_news.png';
    d.ifha_pre[5].src = '/img/ifha_nav_bg_forms.png';
    d.ifha_pre[6].src = '/img/ifha_nav_bg_dirs.png';
    d.ifha_pre[7].src = '/img/ifha_nav_bg_cont.png';

    d.ifha_nav = new Array();
    d.ifha_nav[0] = 'nav_home';
    d.ifha_nav[1] = 'nav_aboutus';
    d.ifha_nav[2] = 'nav_practitioners';
    d.ifha_nav[3] = 'nav_services';
    d.ifha_nav[4] = 'nav_enewsletter';
    d.ifha_nav[5] = 'nav_patientforms';
    d.ifha_nav[6] = 'nav_directions';
    d.ifha_nav[7] = 'nav_contactus';

    d.ifha_rep = new Array();
  }
}

function swapBg(index)  {
  var id = document.ifha_nav[index];
  if (id)  {
    var obj = document.getElementById(id); 
    if (obj)  {
      obj.style.backgroundImage = 'url(' + document.ifha_pre[index].src + ')';
      document.ifha_rep[document.ifha_rep.length] = id;
    }
  }
}

function bgRestore()  {
  var i;
  for (i = 0; i < document.ifha_rep.length; i++)  {
    var id = document.ifha_rep[i];
    var obj = document.getElementById(id); 
    if (obj)  {
      obj.style.backgroundImage = '';
    }
  }
  document.ifha_rep = new Array();
}



usrwiped = passwiped = emailwiped = false;
function wipe_usr () {
    if(!usrwiped){
        document.Form.msUserId.value = "";
        usrwiped = true;
    }
    return true;
}

function wipe_passwd () {
    if(!passwiped){
        document.Form.msPassword.value = "";
        passwiped = true;
    }
    return true;
}


function wipe_email () {
    if(!emailwiped){
        document.form2.email.value = "";
        emailwiped = true;
    }
    return true;
}

