O'Reilly logo

Head First Servlets and JSP, 2nd Edition by Bert Bates, Bryan Basham, Kathy Sierra

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

Two-minute HTML guide

When you develop a web page, you use HTML to describe what the page should look like and how it should behave.

HTML has dozens of tags and hundreds of tag attributes. The goal of HTML is to take a text document and add tags that tell the browser how to format the text. Below are the tags we use in the next several chapters. If you need a more complete understanding of HTML, we recommend the book HTML & XHTML The Definitive Guide (O’Reilly).

Tag

Description

<!-- -->

where you put your comments

<a>

anchor - usually for putting in a hyperlink

<align>

align the contents left, right, centered, or justified

<body>

define the boundaries of the document’s body

<br>

a line break

<center>

center the contents

<form>

define a form (which usually provides input fields)

<h1>

the first level heading

<head>

define the boundaries of the document’s header

<html>

define the boundaries of the HTML document

<input type>

defines an input widget to a form

<p>

a new paragraph

<title>

the HTML document’s title

Note

(Technically, the <center> and <align> tags have been deprecated in HTML 4.0, but we’re using them in some of our examples because it’s simpler to read than the alternative, and you’re not here to learn HTML anyway.)

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