function showDialog(boxDragId,frameSrc){
	boxDragObj = document.getElementById(boxDragId);
	frameObj = boxDragObj.firstChild;
	frameObj.src = frameSrc;
	show(boxDragId);
}

function showFooterDialog(boxDragId,frameSrc){
	showDialog(boxDragId,frameSrc);
}

function hideDialog(boxDragId,parentPageName){
	window.parent.document.getElementById(boxDragId).style.visibility="hidden";
	window.parent.location=parentPageName;
}

 function switch_layers(topId,bottomId){
	var top = parent.document.getElementById(topId);
	var bottom = parent.document.getElementById(bottomId);
	var tmp_max = Math.max(top.style.zIndex,bottom.style.zIndex);
	var tmp_min = Math.min(top.style.zIndex,bottom.style.zIndex);  
	
	if (tmp_max == tmp_min) tmp_max = tmp_min+1;
	top.style.zIndex = tmp_max;
	bottom.style.zIndex = tmp_min;
}

