javascript refresh page on form submit code example
Example 1: submit form javascript without refresh
event.preventDefault()
Example 2: submit() refreshes the page
<form onsubmit="return false;">Form stuff in here</form>
Example 3: why does my form reload the page? html js
document.getElementById("prospects_form").addEventListener('submit', function(event){event.preventDefault();});