Java Reference
In-Depth Information
to obtain an instance of GregorianCalendar , which describes the time at which
the instance was created in the Gregorian calendar —the calendar we use today.
We do not describe the applet in this text because it would require several
pictures and a lot of text. We advise you to watch activity 16-3.1.
HTML and the web
HTML stands for HyperText Markup Language . Html is the language in which
web pages are written. We explain the basics of html, using as an example the
web page of Fig. 16.3, whose source file appears in Fig. 16.4. As you read this
section, continually refer to these two figures.
The name of an html file usually has the suffix .html or . htm .
An html page consists of conventional text interspersed with html tags . An
html tag consists of a command, possibly with arguments, within angle brackets
< and > . As an example, every html page begins with the tag <html> and ends
with the tag </html> Most tags come in pairs: one tag < xxx ...> to start some-
thing and one tag </ xxx ...> to end it. The tags commands are case-insensitive;
the tag <html> could have been written as <HTML> or <HtMl> .
The language html is also insensitive to whitespace (blanks, tabs, end of
lines) in that several whitespace characters in a row are treated as one blank char-
acter. Thus, in an html file, you may see several blank lines, or 20 blanks at the
beginning of a line, but they play the same role as a single blank in determining
how the html page is formated. Therefore, you can use indentation and blank
lines to help exhibit the structure of an html page, just as you do in Java.
If you want to place three blanks in a row on a web page, use the escape
sequence &nbsp; for each blank.
Between the tags <html> and </html> one generally finds two other pairs:
<head> ... </head>
<body> ... </body>
The material between the head-tags can contain various things, such as a title:
<title> A web page </title>
Within the two body-tags is the text that appears in the browser window,
Figure 16.3:
A web page
Search WWH ::

Custom Search