var staffPortlet = {}; 

function alpha(e) {
	var k;
	document.all ? k = e.keyCode : k = e.which;
	
	if(k==8 || k==0) {
		return k;
	}
	
	return ((k > 47 && k < 58));
}

function submitForm(size, fm, message) {
	
	if(document.getElementById(fm+'_odr').value == "") {
		return false;
	}

	var input=document.getElementById(fm+'_odr').value;
	var Int_input =parseInt(input);
	if(Int_input > size) {
		alert(message);
		return false;
	} else {
		
		document.getElementById(fm).submit();
	}
	
}


staffPortlet.goToWithNtification = function(url, message){	
	var hasil = confirm(message);
	if(hasil){
		window.location.href = url
	}
}

function submitSel(){
	document.getElementById("selectForm").submit();
}

staffPortlet.submitSearchValidate = function(){

	if(document.getElementById('name').value==''){
		return false;
	}
	return true;
}


staffPortlet.goToUrl = function(urlGo){
	window.location.href = urlGo
}

