HTML 5 <blockquote><p> Division of Labor and Cooperation

Source: Internet
Author: User

The first thing that comes to mind when you mention a document tag is P, which is to use CSS styles such as margin,padding and text-indent if you want to achieve indentation and spacing.

But now a new label for HTML5 solves all of the above problems, it can self-indent and self-spacing, which is the blockquote tag of a person's credit.

The <blockquote> tag definition is a block reference from another source.

All text between <blockquote> and </blockquote> is separated from the regular text, often indented on the left and right sides (increasing margins), and sometimes using italics. In other words, block references have their own space.

Instance
Chairman Mao said:<blockquote> imperialism is a paper tiger ... </blockquote>

Try it yourself.

If the token is a short reference that does not require paragraph separation, use the <q> element. The blockquote should only be applied to references from another source.

<q> tag tags are short references, and the browser often adds quotes around the referenced content.

Instance
<q>Here's a short quotation here's a short quotation</q>

Try it yourself.

-----------------------------------------------------------

To validate a page as strict XHTML, the <blockquote> element must contain block-level elements, such as:

<blockquote><p>here is a long quotation here is a long quotation</p></blockquote>

----------------------------------------------------------------------------------------

that's the question, how do you make the blockquote paragraph <p> not indent in CSS?

P has been globally defined as two characters in indentation. When the paragraph needs to add blockquote, this line of text is <blockquote><p>, ... ...<p> </blockquote> the text is also indented two characters. What is the way to achieve it?

Best Answer
blockquote{margin:0;} /* Remove the indentation of the blockquote itself. */
Blockquote p{text-indent:0;}
The difference between <q> and <blockquote>

<q> tags are essentially the same as <blockquote>. The difference is in their display and application. <q> tags are used for short inline references. If you need to separate the long sections from the surrounding content (usually shown as indented blocks), use the <blockquote> tab.

HTML 5 <blockquote><p> Division of Labor and Cooperation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.