On front-end edit/submission of a form, when you hit save button, the save button can be clicked again while it is loading. When clicked, it actually submits the data twice. So if it’s a submission form, more than 1 post will be created.
How can we disable the save button while it is loading or submitting data?
We have tried
But they don’t work because the form stops being submitted.