I have a button that I would like to disable when the form submits to prevent the user submitting multiple times.
I have tried naively disabling the button with javascript onclick but then if a client side validation that fails the button remains disabled.
How do I disable the button when the form successfully submits not just when the user clicks?
This is an ASP.NET form so I would like to hook in nicely with the asp.net ajax page lifecycle if possible.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…