

var helpWnd=null;



function isEmpty(form,field)

{

	var txt = form[field].value;

	if(txt=="")return true

	for(var i=0; i<txt.length; i++)

		if(txt.charAt(i)!=" ")

			return false

	 

	return true;

}



	var d = document;

	var isNS = (d.layers)?true:false;

	var isIE = (d.all)?true:false;

	var isDom = (!isIE&&d.getElementById)?true:false;

	var isOpera=navigator.userAgent.indexOf("Opera")!=-1;

	var vis = false;

	



function checkBrowser()

{

	this.ver=navigator.appVersion

	this.dom=document.getElementById?1:0

	this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom)?1:0;

	this.ie4=(document.all && !this.dom)?1:0;

	this.ns5=(this.dom && parseInt(this.ver) >= 5) ?1:0;

	this.ns4=(document.layers && !this.dom)?1:0;

	this.bw=(this.ie5 || this.ie4 || this.ns4 || this.ns5)

	

	return this

}



bw=new checkBrowser()





function showLayer(text)

{

	var ver = navigator.userAgent;

	

	if(ver.search('MSIE') != -1 && ver.search('Opera') == - 1)

	{

		var top_ = document.body.scrollTop-150;

		var left_ = document.body.clientWidth-250;

	}

	else

	{

		var top_ = window.pageYOffset +  + 'px';

		var left_ = window.innerWidth - + 'px';

	}

//	document.getElementById("hint").style.top= top_;

//	document.getElementById("hint").style.left= left_

	if(isDom)

	{

//		alert("this")

		var doc = document.getElementById('hint');

		doc.style.top= top_;

		doc.style.left= left_;

		eval("doc.style.visibility=\'visible\'");

		doc.innerHTML="<div class=\"test\"><p>"+text+"</p></div>";

	}

	if(isIE)

	{

		eval("d.all.hint.style.visibility=\'visible\'");

		d.all.hint.style.top = top_;

		d.all.hint.style.left = left_;

		d.all.hint.innerHTML="<div class=\"test1\"><p>"+text+"</p></div>";

	}

	if(isNS)

	{

		d['hint'].style.top = top_;

		d['hint'].style.left = left_;

		d['hint'].visibility = 'show';

		d['hint'].innerHTML = "<div class=\"test\"><p>"+text+"</p></div>";

	}

	

}



function hideLayer()

{

	if(isDom)

	{

		var doc = document.getElementById('hint');

		eval("doc.style.visibility=\'\'");

	}

	

	if(isIE)

	{

		eval("d.all.hint.style.visibility=\'\'");

	}

	

	if(isNS)

	{

		if (vis == false) setTimeout('d[\'hint\'].visibility = \'hide\';',150);

		else setTimeout('d[\'hint\'].visibility = \'show\';',150);

	}

}

