Answers for "how do we put javascript code inside html file"

80

calling javascript file in html

<script type="text/javascript" src="yourfile.js"></script>
Posted by: Guest on February-23-2020
1

how to write code in external javascript file

function myFunction() {

  document.getElementById("demo").innerHTML = "Paragraph changed.";

}
Posted by: Guest on May-25-2021

Code answers related to "how do we put javascript code inside html file"

Browse Popular Code Answers by Language