Chapter 3. Language Essentials

Now that you’ve gotten your feet wet, let’s wade a bit deeper into the JavaScript language. In this chapter, we’ll go into more detail about the basic elements of JavaScript and introduce you to other aspects of the JavaScript language, such as loops, arrays, and more about functions (don’t let your eyes glaze over; we promise that it’ll be easy).

You’ll see how you can use JavaScript to write your Web pages for you, learn how JavaScript handles errors that the user makes, and much more.

Table 3.1. Just Enough HTML—The Basics

Tag

Meaning

table

Presents tabular data on a Web page

tr

Begins a row inside the table

th

Heading cells for the columns in the table

td

Contains each cell in the table

Around and Around with Loops

It’s common ...

Get JavaScript and Ajax for the Web, Sixth Edition: Visual QuickStart Guide now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.