var isIE = false, isNN5 = false, isNN = false;

if (document.getElementById) {
	isNN5 = true;
} else if (document.all) {
	isIE = true;
} else {
	isNN = true;
}

function getObject (name) {
	var obj = null;

	if (isNN5)
		obj = document.getElementById (name);
	else if (isIE)
		obj = document.all[name];
	else
		return null;

	return obj;
}

function minMax (objName) {
	var obj = getObject (objName);
	var control = getObject (objName + "_c");
	
	if (obj != null && control != null) {
		if (obj.style.height != "0px") {
			obj.style.height = "0px"
			control.innerHTML = "show";
		} else {
			obj.style.height = "auto";
			control.innerHTML = "hide";
		}
	}
}

function launch_app_web (url, winName, width, height) {
	var mywin = window.open(url, winName, 'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1,width=' + width + ',height=' + height);
	mywin.opener = self;

	if (window.focus) mywin.focus();
}

function launch_app_web_scroll (url, winName, width, height) {
	var mywin = window.open(url, winName, 'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=' + width + ',height=' + height);
	mywin.opener = self;

	if (window.focus) mywin.focus();
}
