Website Design with HTML | Phrase Elements
The following elements are not used as widely as the elements you have met so far. As the element namesindicate, they are designed to describe their content:
- <em>and <strong>for emphasis
- <blockquote>, <cite>, and <q>for quotations and citations
- <abbr>, <acronym>, and <dfn>for abbreviations, acronyms, and key terms
- <code>, <kbd>, <var>, and <samp>for computer code and information
- <address>for addresses
<em>and <strong>for emphasis:
Try this Example:
<p><em>Always</em> look at burning magnesium through protective colored glass as it <strong>can cause blindness</strong>.</p>
The <abbr> Element Is for Abbreviations:
For example, if you want to indicate that ECE is an abbreviation for Electronics & Communication Engineering, you can use the <abbr> element like so:
I like <abbr title="Electronics & Communication Engineering">ECE</abbr>.
The <acronym> Element Is for Acronym Use:
For example, if you want to indicate that HTML was an acronym, you can use the <acronym>element like so:
This chapter covers marking up text in <acronym title="Hypertext Markup Language">HTML</acronym>
The <dfn> Element Is for Special Terms:
For example, you can indicate that the term "XHTML" in the following sentence is important and should be marked as such:
This website teaches you how mark up your documents for the Web using <dfn>HTML</dfn>.
The <blockquote> Element Is for Quoting Text:
Try this Example:
<p>The following description of XHTML is taken from the W3C Web site:</p>
<blockquote> XHTML 1.0 is the W3C's first Recommendation for XHTML, following on from earlier work on HTML 5, HTML 4.01, HTML 4.0, HTML 3.2 and HTML 2.0. </blockquote>
The <q> Element Is for Short Quotations:
<p>As Tom said, <q>Somebody's boring me. I think it's me</q>.</p>
The <code> Element Is for Code:
<p><code><h1>This is a primary heading</h1></code></p>
The <kbd> Element Is for Text Typed on a Keyboard:
<p>Type in the following: <kbd>This is the kbd element</kbd>.</p>
The <var> Element Is for Programming Variables:
<p><code>document.write("<var>user-name</var>")</code></p>
The <samp> Element Is for a Program Output:
<p>If everything worked you should see the result <samp>Test completed OK</samp>.</p>
The <address> Element Is for Addresses:
<address>KUET, Khulna-920300, Bangladesh</address>
Subscribe to:
Post Comments
(
Atom
)
No comments :
Post a Comment