Perform Javascript action after reset button handles click

后端 未结 4 1037
天命终不由人
天命终不由人 2021-02-09 15:57

How do I perform an action immediately after an has already reset the form elements?

4条回答
  •  粉色の甜心
    2021-02-09 16:39

    Forms have a reset event that you can listen for.

    
    

    Of course, it's bad practice to add javascript handlers this way, so you'd want to use .addEventListener/.attachEvent or jQuery.bind(), but you get the idea.

提交回复
热议问题