onclick event function in JavaScript

Two observations: You should write <input type=”button” value=”button text” /> instead of <input type=”button”>button text</input> You should rename your function. The function click() is already defined on a button (it simulates a click), and gets a higher priority then your method. Note that there are a couple of suggestions here that are plain wrong, and … Read more