mozilla

Revision 3742 of <blockquote>

  • Revision slug: HTML/Element/blockquote
  • Revision title: blockquote
  • Revision id: 3742
  • Created:
  • Creator: hobophobe
  • Is current revision? No
  • Comment Fix indentation of example.; no changes

Revision Content

The HTML Block Quotation (<blockquote>) element indicates that the enclosed text is an extended quotation. Usually, this is rendered visually by indentation (see Notes for how to change it). A URL for the source of the quotation may be given using the cite attribute, while a text representation of the source can be given using the {{ HTMLElement("cite") }} element.

Usage Context

Permitted content Flow content
Tag omission None, must have both a start tag and an end tag.
Permitted parent elements Any element that accepts flow content.
Normative document HTML5, section 4.5.4; HTML 4.01, section 4.2.2

Attributes

This element has the global attributes shared by all HTML elements.

{{ htmlattrdef("cite") }}
A URL that designates a source document or message for the information quoted. This attribute is intended to point to information explaining the context or the reference for the quote.

Example

<blockquote cite="http://developer.mozilla.org">
  <p>This is a quotation taken from the Mozilla Developer Center.</p>
</blockquote>

Above HTML code will output:

This is a quotation taken from the Mozilla Developer Center.

Notes

To change <blockquote> indent, use CSS margin property.

For short quotes use <q> element.

See also

  • This element exposes the HTMLQuoteElement DOM interface.
  • Use the {{ HTMLElement("q") }}  element for inline quotations.
  • Use the {{ HTMLElement("cite") }} element for source citations.

{{ languages( { "pl": "pl/HTML/Element/blockquote" } ) }}

Revision Source

<p>The HTML <em>Block Quotation</em> (<code>&lt;blockquote&gt;</code>) element indicates that the enclosed text is an extended quotation. Usually, this is rendered visually by indentation (see <a href="/en/HTML/Element/blockquote#Notes" title="en/HTML/Element/blockquote#Notes">Notes</a> for how to change it). A URL for the source of the quotation may be given using the <strong>cite</strong> attribute, while a text representation of the source can be given using the {{ HTMLElement("cite") }} element.</p>
<h2>Usage Context</h2>
<table class="standard-table"> <tbody> <tr> <td>Permitted content</td> <td><a href="/en/HTML/Content_categories#flow_content" title="en/HTML/Content categories#flow content">Flow content</a></td> </tr> <tr> <td>Tag omission</td> <td>None, must have both a start tag and an end tag.</td> </tr> <tr> <td>Permitted parent elements</td> <td>Any element that accepts <a href="/en/HTML/Content_categories#flow_content" title="en/HTML/Content categories#flow content">flow content</a>.</td> </tr> <tr> <td>Normative document</td> <td><a class=" external" href="http://www.w3.org/TR/html5/grouping-content.html#the-blockquote-element" title="http://www.w3.org/TR/html5/grouping-content.html#the-blockquote-element">HTML5, section 4.5.4</a>; <a class=" external" href="http://www.w3.org/TR/html401/struct/text.html#h-9.2.2" title="http://www.w3.org/TR/html401/struct/text.html#h-9.2.2">HTML 4.01, section 4.2.2</a></td> </tr> </tbody>
</table>
<h2>Attributes</h2>
<p>This element has the <a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">global attributes</a> shared by all HTML elements.</p>
<dl> <dt>{{ htmlattrdef("cite") }}</dt> <dd>A URL that designates a source document or message for the information quoted. This attribute is intended to point to information explaining the context or the reference for the quote.</dd>
</dl>
<h2>Example</h2>
<pre class="brush: html">&lt;blockquote cite="http://developer.mozilla.org"&gt;
  &lt;p&gt;This is a quotation taken from the Mozilla Developer Center.&lt;/p&gt;
&lt;/blockquote&gt;
</pre>
<p>Above HTML code will output:</p>
<blockquote cite="http://developer.mozilla.org">
<p>This is a quotation taken from the Mozilla Developer Center.</p>
</blockquote><h2>Notes</h2>
<p>To change <code>&lt;blockquote&gt;</code> indent, use <a href="/en/CSS" title="en/CSS">CSS</a> <a href="/en/CSS/margin" title="en/CSS/margin">margin</a> property.</p>
<p>For short quotes use <a href="/en/HTML/Element/q" title="en/HTML/Element/q"><code>&lt;q&gt;</code></a> element.</p>
<h2>See also</h2>
<ul> <li>This element exposes the <a href="/en/DOM/HTMLQuoteElement" title="en/DOM/HTMLQuoteElement">HTMLQuoteElement</a> DOM interface.</li> <li>Use the {{ HTMLElement("q") }}  element for inline quotations.</li> <li>Use the {{ HTMLElement("cite") }} element for source citations.<a href="/en/HTML/Element/q" title="en/HTML/Element/q"><br> </a></li>
</ul>
<p>{{ languages( { "pl": "pl/HTML/Element/blockquote" } ) }}</p>
Revert to this revision