Its quite familiar that JavaScript need HTML to run .So there are 2 ways in incorporating Java Script in HTML
- Adding Internally
- adding a java script code in html code and save it as file-name.html and run it
- Adding Externally
- Calling a java-script code [.js file] in your HTML code
Here samp.js will be having the code to display the text when the button is clicked