<!--
function getCookieVal (offset) {
var endstr = document.cookie.indexOf (";", offset);
if (endstr == -1)
	endstr = document.cookie.length;
return unescape(document.cookie.substring(offset, endstr));
}

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;
}

function SetCookie (cookiename,cookievalue) {
var largeExpDate;
// Delete old sub-domain cookie
largeExpDate = new Date ();
largeExpDate.setTime(largeExpDate.getTime() + (-1 * 24 * 3600 * 1000));
document.cookie=cookiename + "=; domain=www.nrgi.com; path=/; expires=" + largeExpDate.toGMTString();
// Create domain-level cookie
largeExpDate = new Date ();
largeExpDate.setTime(largeExpDate.getTime() + (365 * 24 * 3600 * 1000));
document.cookie=cookiename + "=" + cookievalue + "; domain=" + location.host.substring(location.host.indexOf(".")+1) + "; path=/; expires=" + largeExpDate.toGMTString();
return null;
}

function isnumeric (s) {
var valid = 1
var sdigits = "0123456789"
var i = 0

if (s=="")
	valid = 0

for (i =0; i <= s.length -1; i++)
	if (sdigits.indexOf(s.charAt(i)) == -1)
			valid = 0
			
return valid
}

function linkcheck() {
var b = window.confirm('Click OK to confirm');
if (b)
	{ }
else
	link1.href=document.location
}

var once;
function onlyonce(twice) {
if (once==twice)
	alert("Please only click this link once")
else
	once=twice
return 0
}

function submitForm(form) {
	form.Submit
}

// -->