【参加讨论】 介绍几个不常用的html标签
在html王国里,这里有很多子民,通常我们看到的是一些熟悉的面孔,而对于那些不熟悉的面孔你又了解多少呢,你知道它们的用法吗?
0、<!doctype> 标签
<!doctype> 标签出现在html文档第一行上的信息,说明该文档的类型,是一个“标准概括化置标语言(sgml)”声明,不是元素。语法:
<!doctype>
例子:<!doctype html public "-//w3c//dtd html 3.0//en">
<!doctype html public "-//w3c//dtd html 4.0 strict//en">
1、<abbr>标签
一个词或短语的简称(如“html”)。通常同时使用title属性来指出原词或原短语。
简称不一定是缩写,但缩写同时也是简称。注:internet explorer还不支持abbr。
<abbr>标记是用来标注一个缩写的,例子:
<abbr title="hyper text marked language">html</abbr><abbr title="cascading style sheets">css</abbr><abbr title="document object model">dom</abbr>
对于单纯浏览没什么用,但是如果想要文本能被搜索,就可以用到。
注意:此元素只能放置在body中,而且使用在文字的行内。
2、<acronym>标签
<acronym>元素允许作者清楚地标识一个组成缩略语的字符序列(如: "www", "fnac", "irs", 等等). 标识缩略语的能力对于拼写检查, 语音系统, 其它的用户代理器工具来说是有用的。
语法:
<acronym
title=text
lang=language
language=javascript | jscript | vbscript | vbs
class=style sheet class name
style=styling
id=value
event = script
>
例子:
<acronym title="federal bureau of investigation">fbi</acronym>
3、base 元素
base 元素指定一个显式 url 用于解析对于外部源的链接和引用,如图像和样式表。
当使用时,base 元素必须出现在文档的 head 内,在任何对外部源的引用之前。
此元素在 microsoft® internet explorer 3.0 的 html 中可用,在 internet explorer 4.0 的脚本中可用。此元素不会被渲染。www.iyit.net(易特网络) 此元素不需要关闭标签。
4、<applet>标签
描述:
引入一个java applet。
语法:
<applet
align=alignment
alt=alternate text
archive=compressed file
class=style sheet class name
code=appletfile
codebase=url
datafld=colname
datasrc=data source
height=n pixels
hspace=n pixels
id=value
name=name
src=url
style=styling
title=text
vspace=n pixels
width=n pixels
event = script
>
例子:
<applet code="coolnav.class" align="baseline" width="168" height="313">
<param name="notice" value="coolmenu2.5,copyright (c) 1999 sourcetec software co. ltd, registered">
<param name="apstyle" value="004080,ff8c8c,,1,0,0,,13,5,004080,1,loading image ...">
...
</applet>
5、<caption>标签
<caption>标签用于显示表格标题,作用是为表格标示一个标题列,有如在表格上方加上一没格线的打通列。 当然亦可置于下方,通常用以存放该表格的标题。
语法:
<caption
align=bottom | center | left | right | top
valign=bottom | top
class=style sheet class name
id=value
lang=language
language=javascript | jscript | vbscript | vbs
style=styling
title=text content
event = script
>
例子:
<table border=1><caption valign=bottom>this caption will appear below the table.
</caption><tr>< td>here</td>is the<td>table.</td></tr></table>