The Web Design Group

q - Short Quotation

Syntax <q>...</q>
Attribute Specifications
Contents Inline elements
Contained in Inline elements, block-level elements

The q element is used for short, inline quotations. For longer (block) quotations, use the blockquote element.

The q element's optional cite attribute provides a URI of the source of the quotation. Some examples follow:

<p>In the words of Albert Einstein, <q>God does <em>not</em> play dice.</q></p>

<p>According to Dave Raggett, <q cite="http://www.w3.org/Press/HTML4-REC">HTML 4.0 gives Web designers the ability to create dynamic visually exciting pages that are accessible to all.</q></p>

Note that authors should not include their own quotation marks when using the q element. However, this can be a problem since almost all current browsers lack support for q. Authors may prefer to avoid q and insert their own quotation marks. Another alternative is to use i in combination with q so that the quotation is distinguished from other text in most browsers. The previous example could also be given as follows:

<p>According to Dave Raggett, <i><q cite="http://www.w3.org/Press/HTML4-REC">HTML 4.0 gives Web designers the ability to create dynamic visually exciting pages that are accessible to all.</q></i></p>

Browsers supporting q should properly handle nested quotations. They should also use quotation marks suitable to the language of the quotation, based on the lang attribute of q or the language of its parent.

More Information