//******************************************************************
//*  Pop-Up Menu Function                                          *
//******************************************************************

function HideDiv(DivName)   
		{
			if(DivName == 'dMain')
			{
				if(document.all.dMain.style.visibility = "visible")
				{
					document.all.dMain.style.visibility = "hidden" ;
				}
			}	
			if(DivName == 'dAbout')
			{	
				if(document.all.dAbout.style.visibility ="visible")
				{
					document.all.dAbout.style.visibility = "hidden" ;
				}
			}
			if(DivName == 'dProduct')
			{
			    if( document.all.dProduct.style.visibility = "visible"){
			      
			      document.all.dProduct.style.visibility = "hidden" ;
			      
			    }
			}
			
			if(DivName == 'dLanguage')
			{
			    if(document.all.dLanguage.style.visibility = "visible")
			    {
			        document.all.dLanguage.style.visibility = "hidden" ;
			    }
			}	
		}
		
function _Cookie_load(){
	//first, get a list of all cookies that pertain to this document.
	//we do this by reading the magic document.cookie property.
	var allcookies = this.$document.cookie;
	if (allcookies == "") return false;
	
	// Now extract just the named cookie from that list.
	var start = allcookies.indexOf(this.$name + '=');
	if (start == -1)return false;  // cookie not defined for this page.
	start += this.$name.length + 1; // skip name and equals sign.
	var end = allcookies.indexOf(';' , start);
	if (end == -1) end = allcookies.length;
	var cookieval = allcookies.substring(start, end);
	
	//Now that we've extracted the value of the named cookie, we've got to break that value
	//down into individual state variable names and vlues. the name/value pairs are separated
	//from each other by ampersands, and the individual names and values are separated from each 
	// other by colons. we use the split method to parse evrything.
	var a = cookieval.split('&'); // break it into array name/value pairs
	for (var i=0; i<a.length; i++){ //break each pair into an array.
		a[i] = a[i].split(':');
	}
	
	// Now that we've parsed the cookie value, set all the names and values of the state variables
	// in this cookie object. Note that we unescape() the property value, because we called escape()
	//when we stored it.
	for (var i=0; i<a.length; i++){
		this[a[i][0]] = unescape(a[i][1]);
	}
	
	return true;
}


function Cookie(document, name, hours, path, domain, secure){
	// The constructor function : creates a cookie object for the specified
	// document, with a specified name and optional attributes.
	// Arguments:
	//   document: The document object that the cookie is stored for. Required.
	//   name:	   A string that specified a name for the cookie. Required.
	//   hours:    An optional number that specified the number of hours from now that
	//             the cookie should expire.
	//   path:     An optional string that specified the cookie path attribute.
	//   domain:   An optional string that specified the cookie domain attribute.
	//   secure:   An optional boolean value, if true, requests a secure cookie.
	// All the predefined properties of this object begin with '$' to distinguish them
	// from other properties which are the values to be stored in the cookie.
	this.$document = document;
	this.$name = name;
	if (hours)
	  this.$expiration = new Date((new Date()).getTime() + hours*3600000);
	else this.$expiration = null;
	if (path) this.$path = path;       else this.$path = null;
	if (domain) this.$domain = domain; else this.$domain = null;
	if (secure) this.$secure = true;   else this.$secure = false;	
}		