<!-- //hides from old browsers
//Written By Buvanenran Rajaratnam
//University of Windsor , Canada 
//rajara1@uwindsor.ca
	var expDays = 3650; //expires 3650 days from today
	var exp = new Date(); //current date
	exp.setTime(exp.getTime() + (expDays*24*60*60*1000));
	
	//get the cookie
	function GetCookie (name) {  
		var arg = name + "=";  
		var alen = arg.length;  
		var clen = document.cookie.length;  
		var i = 0;  
		while (i < clen) {    
		var j = i + alen;    
		if (document.cookie.substring(i, j) == arg)      
		return getCookieVal (j);    
		i = document.cookie.indexOf(" ", i) + 1;    
		if (i == 0) break;   
		}  
		return null;
	}
	//setup the cookie
	function SetCookie (name, value) {  
		var argv = SetCookie.arguments;  
		var argc = SetCookie.arguments.length;  
		var expires = (argc > 2) ? argv[2] : null;  
		var path = (argc > 3) ? argv[3] : null;  
		var domain = (argc > 4) ? argv[4] : null;  
		var secure = (argc > 5) ? argv[5] : false;  
		document.cookie = name + "=" + escape (value) + 
		((expires == null) ? "" : ("; expires=" + expires.toGMTString())) + 
		((path == null) ? "" : ("; path=" + path)) +  
		((domain == null) ? "" : ("; domain=" + domain)) +    
		((secure == true) ? "; secure" : "");
	}
	
	//delete the cookie
	function DeleteCookie (name) {  
		var exp = new Date();  
		exp.setTime (exp.getTime() - 1);  
		var cval = GetCookie (name);  
		document.cookie = name + "=" + cval + "; expires=" + exp.toGMTString();
	}


	//returns the visitor name
	function Who(info){
		var VisitorName = GetCookie('VisitorName')
		if (VisitorName == null) {
		//VisitorName = prompt("Please type in your name\n For a friendly looking page...!","Guest");
		SetCookie ('VisitorName', 'Guest', exp);
		}
		return VisitorName;
	}

	//returns the last time visited
	function When(info){
		var justNow = new Date()
		var WWHTime = 0;
		WWHTime = GetCookie('WWhenH')
		WWHTime = WWHTime * 1
		var lastTime = new Date(WWHTime);
		var intLastVisit = (lastTime.getYear() * 10000)+(lastTime.getMonth() * 100) + lastTime.getDate()
		var lastHereDateFormat = "" + lastTime;
		var dayOfWeek = lastHereDateFormat.substring(0,3)
		var dateMonth = lastHereDateFormat.substring(4,10)
		var timeOfDay = lastHereDateFormat.substring(10,19)
		var year = lastHereDateFormat.substring(23,58)
		var WWHString = dayOfWeek + ", " + dateMonth +" " +year+  " at " + timeOfDay ;
		SetCookie ("WWhenH", justNow.getTime(), exp)
		return WWHString
	}

	function Count(info){
		var counter = GetCookie('counter')
		if (counter == null) {
		counter = 0;
		}
		else{
		counter++;
		}
		SetCookie ('counter', counter, exp);
		return counter;
	}

	function set(){
		VisitorName = prompt("What's your name?");
		SetCookie ('VisitorName', VisitorName, exp);
		SetCookie ('counter', 0, exp);
		SetCookie ('WWhenH', 0, exp);
	}

	function getCookieVal (offset) {  
		var endstr = document.cookie.indexOf (";", offset);  
		if (endstr == -1)    
		endstr = document.cookie.length;  
		return unescape(document.cookie.substring(offset, endstr));
	}

	//  End -->

