📅  最后修改于: 2022-03-11 15:03:51.038000             🧑  作者: Mango
var form = document.getElementById('formID');
var submitButton = document.getElementById('submitID');
form.addEventListener('submit', function() {
// Disable the submit button
submitButton.setAttribute('disabled', 'disabled');
// Change the "Submit" text
submitButton.value = 'Please wait...';
}, false);