Some Scripts can also be placed in external files. Which further used in different web pages according to the needs of the user or a webpage document.
External Scripts are useful and practical when the same code is used in a number of different web pages.
- Save HTML file as Demo.html
We can place the external script reference in <head> or <body> section as well.
- Code, as well as HTML, is easily readable.
- The code can be easily checked by multiple programmers.