
How to add Buttons in JavaScript?

JavaScript buttons can give nice effects to your web page. If done properly, JavaScript buttons give very impressive look and feel.
The code is as-
<SCRIPT LANGUAGE="JavaScript">
<!-- Beginning of JavaScript below this HTML comment line
function showOutput (message) {
alert (message);
}
</SCRIPT>
<BODY>
<FORM name="myForm">
<INPUT NAME="textBox" TYPE="text">
<INPUT NAME="showOut" TYPE="button" VALUE=" JavaScript "
onClick="showOutput(myForm.textBox.value)">
</FORM>
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.