function editMenu(menuId) {

	docUrl = "../popup/menu.php?inp_par[menuId]="+ menuId;

	docTitle = "Edit Content";

	GB_showCenter(docTitle,docUrl,450,750);

    return false;

}



function detMenu(menuId) {

	docUrl = "../popup/detail-menu.php?inp_par[menuId]="+ menuId;

	docTitle = "Detail";

	GB_showCenter(docTitle,docUrl,375,750);

    return false;

}



function addData(dataType) {

	docUrl = "../popup/data.php?inp_par[mode]=add&inp_par[dataType]="+ dataType;

	docTitle = "Add Data";

	GB_showCenter(docTitle,docUrl,500,750);

    return false;

}



function editData(dataId) {

	docUrl = "../popup/data.php?inp_par[mode]=edit&inp_par[dataId]="+ dataId;

	docTitle = "Add Data";

	GB_showCenter(docTitle,docUrl,500,750);

    return false;

}



function detData(dataId) {

	docUrl = "../popup/detail-data.php?inp_par[dataId]="+ dataId;

	docTitle = "Detail";

	GB_showCenter(docTitle,docUrl,375,750);

    return false;

}



function delData(dataId,host,varKirim) {

	if(confirm("Are you sure to delete this data ?")){  

		docUrl = host + "/popup/data.php?inp_par[mode]=del&inp_par[dataId]=" + dataId + varKirim;

		window.location.href=docUrl;

		return true;

	}	

	return false;

}



function addAlbum() {

	docUrl = "../popup/album.php?inp_par[mode]=add";

	docTitle = "Add Album";

	GB_showCenter(docTitle,docUrl,375,750);

    return false;

}



function editAlbum(albumId) {

	docUrl = "../popup/album.php?inp_par[mode]=edit&inp_par[albumId]="+ albumId;

	docTitle = "Add Album";

	GB_showCenter(docTitle,docUrl,375,750);

    return false;

}



function delAlbum(albumId,host,varKirim) {

	if(confirm("Are you sure to delete this album ?")){  

		docUrl = host + "/popup/album.php?inp_par[mode]=del&inp_par[albumId]=" + albumId + varKirim;

		window.location.href=docUrl;

		return true;

	}	

	return false;

}



function addImage(albumId) {

	docUrl = "../popup/image.php?inp_par[mode]=add&inp_par[albumId]=" + albumId;

	docTitle = "Add Image";

	GB_showCenter(docTitle,docUrl,150,500);

    return false;

}



function delImage(host,varKirim) {

	imageId=document.getElementById("imageId").value;

	if(confirm("Are you sure to delete this Image ?")){  

		docUrl = host + "/popup/image.php?inp_par[mode]=del&inp_par[imageId]=" + imageId + varKirim;

		window.location.href=docUrl;

		return true;

	}	

	return false;

}



function setImage(imageId,imageTitle,imageUrl) {

	elemImageId=document.getElementById("imageId");

	if(elemImageId.value==imageId && imageId!=""){

		GB_showImage(imageTitle,imageUrl);	

	}else{

		elemImageId.value=imageId;	

	}	

}

function cari() {
	val=document.getElementById("inp[search]").value;
	if(val.length<=0 || val=="search..."){
		alert('you must fill in the word');
		return false;
	}
return true;
}

function email() {
	mailFirst=document.getElementById("inp[mailFirst]");
	mailSure=document.getElementById("inp[mailSure]");
	mailCompany=document.getElementById("inp[mailCompany]");
	mailTelephone=document.getElementById("inp[mailTelephone]");
	mailAddress=document.getElementById("inp[mailAddress]");
	mailContent=document.getElementById("inp[mailContent]");

	if(mailFirst.value.length<=0){
		alert('you must fill first name');
		mailFirst.focus();
		return false;
	}
	if(mailSure.value.length<=0){
		alert('you must fill sure name');
		mailSure.focus();
		return false;
	}
	if(mailCompany.value.length<=0){
		alert('you must fill company');
		mailCompany.focus();
		return false;
	}
	if(mailTelephone.value.length<=0){
		alert('you must fill telephone');
		mailTelephone.focus();
		return false;
	}
	if(mailAddress.value.length<=0){
		alert('you must fill email');
		mailAddress.focus();
		return false;
	}
	if(mailContent.value.length<=0){
		alert('you must fill comments');
		mailContent.focus();
		return false;
	}

return true;
}

/*function setImage(imageId) {

	document.getElementById("imageId").value=imageId;

}*/


