HTML and CSS Reference
control over selected elements, it is more likely they will be found in separate .css files
to let you produce sweeping changes over an entire document. With one CSS file you
can control the style of one or thousands of documents. External style sheets are cached,
reduce the amount of code, and let you modify an entire site without mangling the
presentation, often known as DHTML.
Behavior. The behavior layer is the layer of a Web page that makes the page perform
allows you to dynamically control the elements of the Web page based on user interac-
tion such as an individual keystroke, moving a mouse, submitting form input, and so
external files, which are then put in libraries where other programmers can share them.
code in its own file and leaving the HTML/XHTML/XML and CSS in their own respec-
the same the HTML document because the files are small and serve to teach a particular
aspect of the language. So for the time being, we will be obtrusive.
you might want to understand this more fully. For the seven rules of unobtrusive Java-
HTML is static. It structures and defines how the elements of a Web page will appear in
the browser; for example, it is used to create buttons, tables, text boxes, and fillout
reacts asynchronously to events triggered by a user. For example, when a user fills out
user input and validate it before sending it off to a server, or cause a new image to appear
if a mouse moves over a link or the user presses a button, reposition objects on the page,
even add, delete, or modify the HTML elements on the fly. Events are discussed in detail
in Chapter 13, “Handling Events,” but you should be made aware of them right at the
many examples throughout this text that make use of them.