HTML Quotations Examples
Example: In this example we demonstrates the use of HTML Quotations in which <bdo> adjusts text directionality.<abbr> clarifies the abbreviation “GfG” with its full title.<address> displays contact information. These elements enhance content organization and readability.
HTML
<!DOCTYPE html> < html > < head > < title >HTML Quotations</ title > </ head > < body > < h3 >w3wiki</ h3 > <!--Normal text--> < p > The quick brown fox jumps over the lazy dog< br /> </ p > <!--Inside <bdo> tag--> < p > < bdo dir = "rtl" >The quick brown fox jumps over the lazy dog</ bdo > </ p > < p > Welcome to < abbr title = "w3wiki" >GfG</ abbr > </ p > < address > < p > Address:< br /> 710-B, Advant Navis Business Park,< br /> Sector-142, Noida Uttar Pradesh – 201305 </ p > </ address > </ body > </ html > |
Output:
Example 2: In this example we use the of HTML quotations, including <blockquote>, <q>, and <cite>, to showcase different ways of representing quoted text and citations within a webpage.
HTML
<!DOCTYPE html> < html > < head > < title >HTML Quotations Example</ title > </ head > < body > < h3 >w3wiki</ h3 > < p >The quick brown fox jumps over the lazy dog< br ></ p > <!-- Inside blockquotes --> < blockquote > < p >The quick brown fox jumps over the lazy dog </ p > </ blockquote > <!-- Inside quotes --> < q >The quick brown fox jumps over the lazy dog</ q > <!-- Cite with title --> < p > The < cite >w3wiki</ cite > is the best site to< br > search for articles and practice problems. </ p > </ body > </ html > |
Output:
HTML Quotations
The HTML Quotation elements are used to insert quoted texts in a web page, that is the portion of texts different from the normal texts in the web page. Below are some of the most used quotation elements of the HTML.
Tag | Description |
---|---|
<abbr> |
Defines abbreviation or acronym. |
<address> |
Defines contact info for the author/owner of a document. |
<bdo> |
Defines text direction, left-to-right or right-to-left. |
<blockquote> |
Defines a section quoted from another source. |
<cite> |
Defines the title of a work, book, article, or publication. |
<q> |
Defines short inline quotation, enclosed in quotation marks. |