JSFiddle - React, Tailwind, and code Playground
HTML
<form action="" method="get" class="priceOptionForm" name="priceOptionForm">
<input name="paypal_email" type="text" value="whatever" id="email">
</label>
<a href="javascript:void(0);" class="bluebtn" id="profile_price" style="width:60px;margin-top:5px;">Save all</a>
</form>
JavaScript
function submitForm() {
document.priceOptionForm.submit();
document.priceOptionForm.method='post';
}
document.onkeydown = function () {
if (window.event.keyCode == '13') {
alert("cao");
}
}
document.getElementById("profile_price").onclick = submitForm;