var form=document.getElementById("abc"); form.onsubmit=function(){ alert("First event") return false } var submitten=form.onsubmit; form.onsubmit=function(){ submitten() alert("First event") return false }