function OpenPage(Url, WinName, Attrib) {
  // insert directly to href, not to onClick
  WinName = window.open(Url, WinName, Attrib);
	WinName.focus();
}

 // browser element support
 var ElemW3C = document.getElementById? true : false;	// IE 5+, Netscape 6+, Opera 5+, Konqueror 2.1+, Mozilla, Gecko
 var ElemNN4 = document.layers? true : false;	// Netscape 4.x
 var ElemIE4 = document.all? true : false;	// IE 4+
 
function HideModule(module, directory) {
	path_img ="img/ico/";
	
	if (ElemW3C) { // IE5+, Mozilla	
		ObjectModule = document.getElementById("module_"+module);
		ObjectArrow = document.getElementById("arrow_"+module);
	}
	else if (ElemIE4) {	// IE 4+
		ObjectModule = document.all.item("module_"+module);
		ObjectArrow = document.all.item("arrow_"+module);
	}	

	if (ObjectModule.style.display == "") {
		ObjectModule.style.display = "none"; // hide
		ObjectArrow.src= directory + path_img + "arrow_down.gif";
	}
	else {
		ObjectModule.style.display = ""; // show
		ObjectArrow.src= directory + path_img + "arrow_up.gif";
	}
		
} // end of f-ction HideModule

function PhotoDetail(id_photo, cl, path) {
	new_win = window.open(path + 'photobank/show.php?cl=' + cl + '&id=' + id_photo + '&type=0','Photo' + id_photo ,'resizable=yes,scrollbars=yes,status=yes,width=690,height=500');
	new_win.focus();
} // end of f-ction PhotoDetail

function MapDetail(cl, path) {
	new_win = window.open(path + 'open/map/show.php?cl=' + cl, 'Map' + cl ,'resizable=yes,scrollbars=yes,status=yes,width=690,height=500');
	new_win.focus();
} // end of f-ction PhotoDetail

function MapDetailCmn(cl, path) {
	// open map detail common page (classic & noframe design)
	new_win = window.open(path + 'module/contact/map.php?cl=' + cl, 'Map' + cl ,'resizable=yes,scrollbars=yes,status=yes,width=690,height=500');
	new_win.focus();
} // end of f-ction PhotoDetail
