var NS8_displayLike_IE = false
var NS8_displayLike_Firefox = false

var agt=navigator.userAgent.toLowerCase();
//alert(agt)

if ( (agt.indexOf('msie') != -1) && (agt.indexOf('netscape/8') != -1) )
{
	NS8_displayLike_IE = true
}
if ( (agt.indexOf('gecko') != -1) && (agt.indexOf('netscape/8') != -1) )
{
	NS8_displayLike_Firefox = true
}

function WindowOpen(url, name, features)
{
	if (NS8_displayLike_IE)
	{
		var args
		var i
		var dimesion
		var tokens
		args = features.toLowerCase().split(',')
		features=''
		for (i=0; i<args.length; i++)
		{
			if (args[i].indexOf('height')!=-1)
			{
				tokens = args[i].split('=')
				dimesion = parseInt(tokens[1]) + 40
				args[i] = tokens[0] + '=' + dimesion
			}
			features += args[i] + ','
		}
	}
	return window.open(url, name, features)
}

function blockEvents() 
{
	window.onfocus = checkModal
}

function unblockEvents() 
{
	window.onfocus = null; 
	//if (field != null)	field = 'popup';
} 

function LoadBlockEvents() 
{ 
	if (opener) 
		if (!opener.closed) 
			opener.blockEvents();
}
function UnloadBlockEvents() 
{
	if (opener) 
		if (!opener.closed) 
			if (opener.unblockEvents != null)
				opener.unblockEvents();   
}