how to create a alert when a button is clicked code example Example: simple alert program in javascript alert("this is the alert")