document.addEventListener('DOMContentLoaded', function() { document.getElementsByTagName('form')[0].addEventListener('submit', function (e) { e.preventDefault(); }) });