function ask(question,def,res)
{
var name=prompt(question,def);
if (name!=null && name!="")
  {
	  window.location.href=res + name; 
  }
} 

function yakin(word,to)
{
 var where_to= confirm("Apa anda yakin "+ word +"?");
 if (where_to== true)
 {
   window.location=to;
 }
 else
 {
   
  }
} 

var emailfilter=/^\w+[\+\.\w-]*@([\w-]+\.)*\w+[\w-]*\.([a-z]{2,4}|\d+)$/i 
function checkmail(e){
	var returnval=emailfilter.test(e.value)
	if (returnval==false){
	alert("Mohon memasukkan alamat email yang valid")
	e.select()
	}
	return returnval
}
 
 
 function tanya(kata,to)
{
 var ask= confirm("Anda yakin akan "+ kata +"?");
 if (ask== true)
 {
   window.location=to;
 }
 else
 {
   
  }
} 
  
