A rule of thumb in HTML is that, for display of content in a visual
browser, line breaking is determined by THE BROWSER. This power
is given to the browser due to the intrinsic uncertainty of the size
and nature of the display area for an HTML document. Of course, there are
cases when an author will occasionally wish to force a line break in a
document. Thankfully, HTML provides this facility. It also provides a means
of explicitly controlling general line breaking behavior as well. It is
generally safer to leave this behavior in the hands of the browser, but
several extensions to HTML in other areas have made the normal line breaking
behavior inadequate to handle many design situations.
The simplest of the line breaking control mechanisms is the BR element
which forces a line break within document content. Several extensions to
this element control line breaking under the special situations arising from
using floating objects (such as images and tables.) The two remaining line
break elements, NOBR and WBR, are used in situations where the author wants to
disable the basic HTML behavior. NOBR turns off the normal line breaking
behavior in a document, and the WBR element is used to explicitly break up
content within a NOBR section.
In addition to these explicit line breaking mechanisms, there are several
other HTML elements whose intent is not specifically to control line breaking,
but is an added benefit. The Listing,
Plaintext, Pre, and
Xmp elements all disable the normal HTML line breaking
behavior to some degree. Use your best judgment as to which element best
suits your needs.