// JavaScript Document



if(typeof(predir)=="undefined") {

	var predir = './';

}



meetourcrewimg = new Image();

meetourcrewimg.src = predir + 'images/meet-us/meet-our-crew.gif';



meganimg = new Image();

meganimg.src = predir + 'images/meet-us/megan.gif';

marcimg = new Image();

marcimg.src = predir + 'images/meet-us/marc.gif';

reneeimg = new Image();

reneeimg.src = predir + 'images/meet-us/renee.gif';

kymimg = new Image();

kymimg.src = predir + 'images/meet-us/kym.gif';

tammyimg = new Image();

tammyimg.src = predir + 'images/meet-us/tammy.gif';

tonyimg = new Image();

tonyimg.src = predir + 'images/meet-us/tony.gif';

sheriimg = new Image();

sheriimg.src = predir + 'images/meet-us/sheri.gif';

ronnieimg = new Image();

ronnieimg.src = predir + 'images/meet-us/ronnie.gif';



bmeganimg = new Image();

bmeganimg.src = predir + 'images/meet-us-big/megan.gif';

bmarcimg = new Image();

bmarcimg.src = predir + 'images/meet-us-big/marc.gif';

breneeimg = new Image();

breneeimg.src = predir + 'images/meet-us-big/renee.gif';

bkymimg = new Image();

bkymimg.src = predir + 'images/meet-us-big/kym.gif';

btammyimg = new Image();

btammyimg.src = predir + 'images/meet-us-big/tammy.gif';

btonyimg = new Image();

btonyimg.src = predir + 'images/meet-us-big/tony.gif';

bsheriimg = new Image();

bsheriimg.src = predir + 'images/meet-us-big/sheri.gif';

bronnieimg = new Image();

bronnieimg.src = predir + 'images/meet-us-big/ronnie.gif';



var curbioid = null;



function newXmlHttp() {

	var xmlHttp=null;

	try {

	   // Firefox, Opera 8.0+, Safari, IE7+

	   xmlHttp = new XMLHttpRequest(); // xmlHttp is now a XMLHttpRequest.

	} catch (e) {

	   // Internet Explorer

	   try {

		  xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");

	   } catch (e) {

		  xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");

	   }

	}

	

   xmlHttp.onreadystatechange = function() {

   if (xmlHttp.readyState == 4)

      try { // In some instances, status cannot be retrieved and will produce an error (e.g. Port is not responsive)

         if (xmlHttp.status == 200) {

            //Set the main HTML of the body to the info provided by the AJAX Request

			updatebio(curbioid,xmlHttp.responseText);

         }

      } catch (e) {

         ;

      }

	}

	return xmlHttp;

}



function bmeetrestore(bioid) {

	document.getElementById('bigpeopleimg').src = predir + 'images/meet-us-big/big-people.gif';

	document.getElementById(bioid).style.visibility = 'hidden';

}



function bmeetswap(name,bioid) {

	document.getElementById('bigpeopleimg').src = predir + 'images/meet-us-big/' + name + ".gif";

	curbioid = bioid;

	xmlHttp = newXmlHttp();

	xmlHttp.open("get",predir + "bios/"+name+".html"); // .open(RequestType, Source);

	xmlHttp.send(null); // Since there is no supplied form, null takes its place as a new form.

	document.getElementById(bioid).style.visibility = 'visible';

}



function meetrestore(bioid) {

	document.getElementById('meet-us-img').src = meetourcrewimg.src;

	document.getElementById(bioid).style.visibility = 'hidden';

}



function meetswap(name,bioid) {

	document.getElementById('meet-us-img').src = predir + 'images/meet-us/' + name + ".gif";

	curbioid = bioid;

	xmlHttp = newXmlHttp();

	xmlHttp.open("get",predir + "bios/"+name+".html"); // .open(RequestType, Source);

	xmlHttp.send(null); // Since there is no supplied form, null takes its place as a new form.

	document.getElementById(bioid).style.visibility = 'visible';

}



function updatebio(bioid,data) {

	document.getElementById(bioid).innerHTML = data;

}

