function checkTextBox (s) {
	if (s.length > 0)
	return true
	else
	return false;
}

function checkEmail(str) {

		var at="@"
		var dot="."
		var lat=str.indexOf(at)
		var lstr=str.length
		var ldot=str.indexOf(dot)
		if (str.indexOf(at)==-1){
		   return false
		}

		if (str.indexOf(at)==-1 || str.indexOf(at)==0 || str.indexOf(at)==lstr){
		   return false
		}

		if (str.indexOf(dot)==-1 || str.indexOf(dot)==0 || str.indexOf(dot)==lstr){
		    return false
		}

		 if (str.indexOf(at,(lat+1))!=-1){
		    return false
		 }

		 if (str.substring(lat-1,lat)==dot || str.substring(lat+1,lat+2)==dot){
		    return false
		 }

		 if (str.indexOf(dot,(lat+2))==-1){
		    return false
		 }
		
		 if (str.indexOf(" ")!=-1){
		    return false
		 }

 		 return true					
	}

function openWin (loc,width,height,left,top) {
msg=window.open(loc,"msg","height="+height+",width="+width+",left="+left+",top="+top);
msg.topmargin = 0;
msg.leftmargin = 0;
msg.marginwidth = 0;
msg.marginheight = 0;
msg.window.focus();
}

function tocItem (name) {
this.on = new Image();
this.on.src = "/images/" + name + "_over.gif"
this.off = new Image();
this.off.src = "/images/" + name + ".gif"
}

function sideDot () {
this.red = new Image();
this.red.src = "/images/dot_red.gif"
this.green = new Image();
this.green.src = "/images/dot_green.gif"
this.orange = new Image();
this.orange.src = "/images/dot_orange.gif"
}

function toc_new (name) {
tocItem[name] = new tocItem(name);
}

function img_act (imgName)
// Show Image
{
if (document.images)
	document[imgName].src = tocItem[imgName].on.src;
}

function img_inact (imgName)
// Hide Image
{
if (document.images)
    document[imgName].src = tocItem[imgName].off.src;
}


function form_done (imgName)
// Show Image
{
if (document.images)
	document[imgName].src = dot.green.src;
}

function form_inprogress (imgName)
// Hide Image
{
if (document.images)
    document[imgName].src = dot.orange.src;
}

function form_undone (imgName)
// Hide Image
{
if (document.images)
    document[imgName].src = dot.red.src;
}

if (document.images != null) {
dot = new sideDot();
}

var browserName = navigator.appName;
var browserVersion = parseInt(navigator.appVersion);
var browser;
// Style Sheet Additions
if (browserName == "Netscape" && browserVersion < 5)
document.writeln("<link rel=\"stylesheet\" href=\"/includes/netscape.css\" type=\"text/css\">")
else if (browserName == "Netscape" && browserVersion >= 5)
document.writeln("<link rel=\"stylesheet\" href=\"/includes/netscape6.css\" type=\"text/css\">")
