function isValue(id) {
	var v = document.getElementById(id).value;
	return v != null && v != '';
}

function modalTop() {
	if (RichFaces.navigatorType() == 2) {
		return 10;
	} else {
		return 'auto';
	}
}

function ieBottomMargin(height) {
	if (RichFaces.navigatorType() == 0) {
		document.write('<div style="height: ' + height + 'px;">&nbsp;</div>');
	}
}

function openwindow(h, v, page) {
	var options = "toolbar=no,location=no,directories=no,status=no,"
			+ "menubar=no,scrollbars=yes,resizable=no,copyhistory=no,"
			+ "width=" + h + ",height=" + v;
	window.open(page, "blank", options);
}

function hidediv(a) {
	if (document.getElementById) {
		document.getElementById(a).style.display = "none"
	} else {
		if (document.layers) {
			document.id.display = "none"
		} else {
			document.all.id.style.display = "none"
		}
	}
}

function showdiv(a) {
	if (document.getElementById) {
		document.getElementById(a).style.display = "block"
	} else {
		if (document.layers) {
			document.id.display = "block"
		} else {
			document.all.id.style.display = "block"
		}
	}
}
