onclick event button javascript example
Example: javascript onclick
document.getElementById("myBtn").addEventListener("click", function() {
alert("Hello World!");
});
document.getElementById("myBtn").addEventListener("click", function() {
alert("Hello World!");
});