Explanations:
- Look at the file's content source: IE: Use menu "Page-View Source", Firefox: Use "Menu View->PageSource"
- In the head element we define JavaScript code to be imported
- This code will modify some contents through DOM scripting, something we will learn towards the end of the course.
- In the JavaScript code we find several programming concepts: The concept of Event Handling, the function and DOM scripting. We shall come back later to these in more detail
- This example also demonstrates the modern way of using JavaScript. Code is defined in an external file and works independently from HTML code.
Exercise:
- Please edit the associated JavaScript file to change the "hello world" title into something else