changed so that when there are errors, the browser scrolls to the first error
disable submit button when submitting an html form to avoid duplicate submits