Home Web Front-end HTML Tutorial What does the html small tag mean? Examples of how to use the small tag

What does the html small tag mean? Examples of how to use the small tag

Aug 22, 2018 pm 01:59 PM
html small

html small标签是什么意思?small标签的使用方法实例及一些使用技巧都在本篇文章内,接下来将为大家详细介绍html small标签的定义和用法解释,还有html small标签的使用说明,以及关于small标签的一些使用的心得技巧。

html small标签的定义和用法:

<small> 标签呈现小号字体效果。

<small> 标签和它所对应的 <big> 标签一样,但它是缩小字体而不是放大。如果被包围的字体已经是字体模型所支持的最小字号,那么 <small> 标签将不起任何作用。

与 <big> 标签类似,<small> 标签也可以嵌套,从而连续地把文字缩小。每个 <small> 标签都把文本的字体变小一号,直到达到下限的一号字。

HTML <small> 标签实例

定义小型文本:

&lt;p&gt; runoob.com - the world&#39;s largest web development site.&lt;/p&gt;
&lt;p&gt;&lt;small&gt; Copyright 1999-2050 by Refsnes Data.&lt;/small&gt;&lt;/p&gt;
Copy after login

html small标签应用之使用实例:

&lt;p&gt;PHP中文网&lt;small&gt;关于前端和后台的学习网站&lt;/small&gt;&lt;/p&gt;
Copy after login

语义:定义浏览器显示文本要以比当前字体稍小的字体显示.

实例源代码:

&lt;html&gt;
&lt;head&gt;
&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=gb2312&quot;&gt;
&lt;title&gt;字体文本标签讲解&lt;small&gt;&lt;/small&gt;标签&lt;/title&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;p&gt;字体文本标签讲解&amp;lt;small&amp;gt;&amp;lt;/small&amp;gt;标签&lt;/p&gt;
&lt;p&gt;字体标签定义字体的显示效果,有些标签它有独自的语义。&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&amp;lt;small&amp;gt;&amp;lt;/small&amp;gt;标签&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;small&gt;&amp;lt;small&amp;gt;感谢您对PHP中文网的支持&amp;lt;/small&amp;gt;&lt;/small&gt;
&lt;/p&gt;
&lt;p&gt;语义:显示文本要以比当前字体稍小的字体显示.&lt;/p&gt;
&lt;/body&gt;
&lt;/html&gt;
Copy after login

关于html small标签的一个解释和使用的一些技巧

关于<small></small>,网上搜索下来的结果也很零碎,有的说不建议使用,也有的在废弃标签里没有提到它的名字。好在《精通HTML 语义、标准和样式》一书中对此作了详细的解释。 

<small>和<hr><pre><sup><sub><i><b>等一帮兄弟一样,被定义为表示性元素,W3C的说法是:为能够简单地指定字体信息的元素,无语义。

回到淘宝的这一段代码中,<small></small>标记之中是一段跳过导航的链接:<a class="invisible" href="#Content">跳过导航及工具栏</a>。我认为,淘宝UED在思考之后采用了和<i>标记一样的思路,与其定义一个<span class="skipNavigation"></span>占用大量html空间,不如直接使用<small>。更重要的一点是跳过导航的功能就是为用户,准确的说是为残疾人用户在使用朗读浏览器或者无css样式定义的情况下使用的,简洁的<small></small>可能更符合标准化的精神。 

浏览器支持

所有主流浏览器均支持 <small> 标签。

HTML 4.01 与 HTML5 之间的差异

实际运用时没有区别。在 HTML 4.01 中,small 元素显示为更小的文本。在 HTML5 中,small 元素定义旁注信息,并显示为更小的文本。

【小编的相关推荐文章】

html font标签是什么?<font>标签的属性的详细介绍

html5 output标签是什么意思?html5 output标签的使用方法

The above is the detailed content of What does the html small tag mean? Examples of how to use the small tag. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot Article Tags

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Nested Table in HTML Nested Table in HTML Sep 04, 2024 pm 04:49 PM

Nested Table in HTML

Table Border in HTML Table Border in HTML Sep 04, 2024 pm 04:49 PM

Table Border in HTML

HTML margin-left HTML margin-left Sep 04, 2024 pm 04:48 PM

HTML margin-left

HTML Table Layout HTML Table Layout Sep 04, 2024 pm 04:54 PM

HTML Table Layout

Moving Text in HTML Moving Text in HTML Sep 04, 2024 pm 04:45 PM

Moving Text in HTML

HTML Ordered List HTML Ordered List Sep 04, 2024 pm 04:43 PM

HTML Ordered List

HTML onclick Button HTML onclick Button Sep 04, 2024 pm 04:49 PM

HTML onclick Button

How do you parse and process HTML/XML in PHP? How do you parse and process HTML/XML in PHP? Feb 07, 2025 am 11:57 AM

How do you parse and process HTML/XML in PHP?

See all articles