当前位置: 首页 > 网络学院 > 网页制作基础教程 > HTML > HTML <span>标签

HTML
HTML Head
HTML Meta
HTML URLs
HTML Scripts
HTML 属性
HTML 事件
HTML URL-encode
HTML Web服务器
HTML 摘要
HTML 实例
标签列表
标准属性
事件属性
ASCII码
特殊字符
HTTP状态消息

HTML <span>标签


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-03-04   浏览: 581 ::
收藏到网摘: n/a

定义与用法

The <span> tag is used to group inline-elements in a document.
<span>标签可用来在文档内聚集内联元素


在HTML和XHTML中的区别

NONE


提示与注意点

Tip: Use the <span> tag to group inline-elements to format them with styles
提示:使用<span>标签来聚集内联元素,并用样式来格式化它们


实例

代码 输出结果
<p>This is a paragraph <span style="color:#0000FF;">This is a paragraph</span> This is a paragraph</p>

<p>
<span style="color:#00DD45;">
This is another paragraph
</span>
</p>

This is a paragraph This is a paragraph This is a paragraph

This is another paragraph



标准属性

id, class, title, style, dir, lang, xml:lang

For a full description, go to Standard Attributes.
查看完整的属性

事件属性

onclick, ondblclick, onmousedown, onmouseup, onmouseover, onmousemove, onmouseout, onkeypress, onkeydown, onkeyup

For a full description, go to Event Attributes.
查看完整的属性

评论 (0) All

登陆 | 还没注册?