JSFiddle - React, Tailwind, and code Playground
by hescano
HTML
<input type="button" id="SP_BT_Save" value="click me" />
<form id="User_Finder" action="">
</form>
JavaScript
var myVar;
$(document).ready(function() {
$('#SP_BT_Save').click(function() {
myVar=window.setTimeout(save_speciality, 1000);
});
});
function save_speciality() {
clearTimeout(myVar);
alert( document.getElementById('User_Finder'));
document.getElementById('User_Finder').action = "Controler/controller_page.php?button=save_speciality";
document.getElementById("User_Finder").submit();
}