Use HTML5 attribute and document.ready for attaching event to button.