Changed onsubmit events to onclick