Linking to an external JavaScript file
suggest change<script src="example.js"></script>
The src
attribute works like the href attribute on anchors: you can either specify an absolute or relative URL. The example above links to a file inside the same directory of the HTML document. This is typically added inside the <head>
tags at the top of the html document
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents