O'Reilly logo

HTML5 Digital Classroom by AGI Creative Team, Jeremy Osborn

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Lesson 8: Introduction to JavaScript and jQuery

web10.psd

In this lesson, you’ll learn the fundamentals of adding interactivity to your pages with JavaScript and the jQuery JavaScript library.

What you’ll learn in this lesson:

  • An overview of how to use JavaScript
  • How to use the jQuery JavaScript library

Starting up

You will work with several files from the HTML5_08lessons folder in this lesson. Make sure you have loaded the HTML5lessons folder onto your hard drive from www.digitalclassroombooks.com/HTML5. See “Loading lesson files” in the Starting Up section of this book.

3054.jpg This lesson uses the TextWrangler text editor to create the markup, but you can use any text editor and achieve the same results.

Interactivity on the Web

The Web is an interactive medium by nature, and hyperlinks are good examples of this. Even the most basic website requires user interaction, and the decisions made by the designer can affect the user’s perception of the site as well as their experience. HTML offers very few possibilities for interaction, but by adding CSS, you have options such as CSS rollovers and the ability to style hyperlinks. CSS does have certain limitations, which you can overcome by using the JavaScript scripting language and interactive media such as Flash.

A form button with no JavaScript ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required