function checkBrowser()
{
	this.br = navigator.appName.toLowerCase();
	this.version = navigator.appVersion.toLowerCase();
	this.agent = navigator.userAgent.toLowerCase();
	this.is_safari = ( this.version.indexOf( 'safari' ) != -1 );
	this.is_opera = ( this.agent.indexOf( 'opera' ) != -1 );
	this.is_mozilla = ( this.agent.indexOf( 'gecko' ) != -1 );
	this.is_ns = ( this.br == 'netscape' && !this.is_opera );
	this.is_ie = ( this.br == 'microsoft internet explorer' && !this.is_opera );
	this.is_dom = ( document.getElementById ) ? true:false;
}
br = new checkBrowser();


function CUIPopUp( cui_url, cui_parameters, popname )
{
 if( popname != '' )
 {
	 var usename = popname;
 }
 else
 {
	 var random_windowname = Math.round( ( Math.random() * 100 ) );
	 var usename = 'CUIpop' + random_windowname;
 }
 newWindow = window.open( cui_url, usename, cui_parameters );
}


function CUIImageChange( cui_img_name, cui_img_src )
{
 if( document.images[ cui_img_name ] )
 {
	 document.images[ cui_img_name ].src = cui_img_src;
 }
}

function checkRefForm( f )
{
	var ret = false;
	if( f )
	{
		if( f.elements )
		{
			ret = true;
		}
	}
	return true;
}