HTML blockquote标记

本文概述

  • 样式化< blockquote> 标签
  • 属性
  • 支持的浏览器
HTML < blockquote> 标记用于定义从另一个来源引用的文本块。浏览器通常将< blockquote> 标记内的内容显示为缩进文本。
如果要插入长引号, 请使用< blockquote> , 对于短或内联引号请使用< q> 标记。
句法
< blockquote> quoted text......< /blockquote>

以下是有关< blockquote> 标签的一些规范
显示
开始日期/结束日期 开始标签和结束标签
Usage Semantic/textual

< !DOCTYPE html> < html> < head> < title> Blockquote tag< /title> < /head> < body> < h2> Example of blockquote tag< /h2> < p> A Great Motivational Quote :< /p> < blockquote cite="https://www.brainyquote.com/authors/erin_cummings"> < p> At the end of the day, you are solely responsible for your success and your failure. And the sooner you realize that, you accept that, and integrate that into your work ethic, you will start being successful. As long as you blame others for the reason you aren't where you want to be, you will always be a failure.< /p> < /blockquote> < cite> Erin Cummings< /cite> < /body> < /html>

立即测试
输出:
HTML blockquote标记

文章图片
样式化< blockquote> 标签
< !DOCTYPE html> < html> < head> < title> Blockquote tag< /title> < style> blockquote{text-align: justify; background-color: #F7EAE9; border-radius: 4px; margin-right: 25px; }cite{margin-left: 15px; }< /style> < /head> < body> < h2> Example of blockquote tag< /h2> < p> A Great Motivational Quote:< /p> < blockquote cite="https://www.brainyquote.com/authors/erin_cummings"> < p> At the end of the day, you are solely responsible for your success and your failure. And the sooner you realize that, you accept that, and integrate that into your work ethic, you will start being successful. As long as you blame others for the reason you aren't where you want to be, you will always be a failure.< /p> < /blockquote> < cite> -Erin Cummings< /cite> < /body> < /html>

【HTML blockquote标记】立即测试
注意:我们已经使用CSS属性margin-right:25px来更改应用于文本的缩进。你还可以使用margin-left或margin速记属性。 输出:
HTML blockquote标记

文章图片
属性 标签特定属性
属性 描述
cite URL 它用于指定引用来源的URL。
全局属性
< blockquote> 标记支持HTML中的所有全局属性。
事件属性
< blockquote> 标记支持HTML中的所有事件属性。
支持的浏览器
Element Chrome IE Firefox Opera Safari
< blockquote> Yes Yes Yes Yes Yes

    推荐阅读