HTML and CSS Reference
The original image
on the left, and the
swapped image on
the right, with the
hovering on the
In this chapter we will touch on some of the highlights and concepts involved in using
mouseovers, and some of the techniques involved in checking a form for input errors.
the techniques are developed.
browser. This means that the Web browser is capable of understanding the code and
running it. The examples in this chapter use the Mozilla Firefox Web browser. The code
we will be creating will work in most Web browsers. However, we will use Firefox
because it will provide us with helpful error messages that will be invaluable when we
create and test our pages. If you have not already installed Mozilla Firefox on your
computer, visit http://www.mozilla.com/firefox for a free download.
or encapsulated, in <script> and </script> tags to identify it. Web pages are ren-
dered by the Web browser from top to bottom. The impact on our scripts is that they
will execute wherever they are located in the document, as we will see.
For XHTML conformance, the <script> tag must include an attribute to identify the
acter data declaration. When the W3C validator checks for XHTML Strict conformance, it
will check all the code on the page except for areas marked as character data sections.
apply to Web pages coded using Transitional XHTML. However, it doesn't do any harm to
add the character data declaration if you are using Transitional XHTML, so let's include it.
XHTML comments are contained between <!-- and --> markup symbols. These comment
slash) identifies a single comment line and the /* and */ symbols identify a comment block.