function show_alert() { if(confirm("Do you really want to do this?")) document.forms[0].submit(); else return false; }