// Copyright 2008, MCM Enterprises


// Code for Drop Down Menu
function Drop_Menu (){ 
 	if(navigator.appVersion.indexOf("MSIE")==-1){return;}
	
 	var i,k,g,lg,r=/\s*hvr/,nn='',c,cs='hvr',bv='nav';		
		
	for(i=0;i<10;i++){
		g=document.getElementById(bv+nn);
		if(g){
			lg=g.getElementsByTagName("LI");
				if(lg) {
					for(k=0;k<lg.length;k++){
						lg[k].onmouseover=function(){
							c=this.className;cl=(c)?c+' '+cs:cs;
							this.className=cl;
						};
						lg[k].onmouseout=function(){
							c=this.className;
							this.className=(c)?c.replace(r,''):'';
						};
					}
				}
		}
		nn=i+1;
	}
	/*getContent ('../home.htm');*/
}


//Code for filling the parchment
var asyncRequest; // variable to hold XMLHttpRequest object

  // set up and send the asynchronous request.
  function getContent( url ) {
      // for MOSe browsers
		 if(window.XMLHttpRequest && !(window.ActiveXObject))
		 {
			 // attempt to create the XMLHttpRequest and make the request
			 try
			 {
				asyncRequest = new XMLHttpRequest(); // create request object
	
			 } // end try
			 catch ( exception )
			 {
				alert("Your browser does not support AJAX!");
			 } // end catch
		 }
		 // for IE/Windows ActiveX browsers
		 else if(window.ActiveXObject)
		 {
				try
				{
					asyncRequest = new ActiveXObject("Msxml2.XMLHTTP");
				} 
				catch ( exception )
				{
					try
					{
						asyncRequest = new ActiveXObject("Microsoft.XMLHTTP");
					} 
					catch ( exception )
					{
						alert("Your browser does not support AJAX!");
						asyncRequest = false;
					}
				}
		}
		if(asyncRequest)
		{
			asyncRequest.onreadystatechange = stateChange;
			asyncRequest.open("GET", url, true);
			asyncRequest.send("");
		}
  } // end function getContent
      
  // displays the response data on the page
  function stateChange()
  {
	 if ( asyncRequest.readyState == 4 && asyncRequest.status == 200 )
	 {
		document.getElementById( 'main' ).innerHTML = '';
		document.getElementById( 'main' ).innerHTML= asyncRequest.responseText; // places text in contentArea
	 }
		/*else  //browsers do not like this part!!!
		{
			alert("Problem retrieving data:" + asyncRequest.statusText);
		}*/
	 
  } // end function stateChange

//window.onload = getContent ('home.htm');  // added to the bottom of the html (index page)