Two levels of emphasis are available in
XHTML, em
and
strong
. em
is for a
normal level of emphasis and strong
indicates stronger emphasis.
em
is typically rendered in italic
and strong
is rendered in bold. This is
not always the case, and should not be relied upon. According
to best practices, web pages only hold structural and
semantical information, and stylesheets are later applied to
them. Think of semantics, not formatting, when using these
tags.
em
and
strong
ExampleUsage:
<p>
<em>
This</em>
has been emphasized, while<strong>
this</strong>
has been strongly emphasized.</p>
Content that should be rendered in a fixed pitch
(typewriter) typeface is tagged with tt
(for “teletype”).
Links are also inline elements.
A link points to the URL of a
document on the web. The link is indicated with
a
, and the
href
attribute contains
the URL of the target document. The
content of the element becomes the link, indicated to the
user by showing it in a different color or with an
underline.
<a href="...">
Usage:
<p>
More information is available at the<a href="http://www.&os;.org/">
&os; web site</a>
.</p>
This link always takes the user to the top of the linked document.
To link to a specific point within a document, that
document must include an anchor at the
desired point. Anchors are included by setting the
id
attribute of an
element to a name. This example creates an anchor by
setting the id
attribute of a p
element.
Usage:
<p id="samplepara">
This paragraph can be referenced in other links with the name<tt>
samplepara</tt>
.</p>
Links to anchors are similar to plain links, but include
a #
symbol and the anchor's
ID at the end of the
URL.
The samplepara
example is part of a
document called foo.html
. A link to
that specific paragraph in the document is constructed in
this example.
<p>
More information can be found in the<a href="foo.html#samplepara">
sample paragraph</a>
of<tt>
foo.html</tt>
.</p>
To link to a named anchor within the same document, omit
the document's URL, and just use the
#
symbol followed by the name of the
anchor.
The samplepara
example
resides in this document. To link to it:
<p>
More information can be found in the<a href="#samplepara">
sample paragraph</a>
of this document.</p>
All FreeBSD documents are available for download at https://download.freebsd.org/ftp/doc/
Questions that are not answered by the
documentation may be
sent to <freebsd-questions@FreeBSD.org>.
Send questions about this document to <freebsd-doc@FreeBSD.org>.