PUBLIC:COMPONENT元素
--------------------------------------------------------------------------------------
以HTC指明文件的内容。
微软Internet Explorer 6中的新内容
literalContent属性作为一个新的可能值支持嵌套,创建一份嵌套的文字内容元素行为。
格式
<PUBLIC:COMPONENT
ID = "sID"
lightWeight = "bLight"
literalContent = "sLiteral"
NAME = "sName"
supportsEditMode = "bEditable"
tagName = "sTagName"
URN = "sURN"
>
<!-- 子级元素 -->
</PUBLIC:COMPONENT>
属性
ID
可选。组件内PUBLIC:COMPONENT元素的唯一识别字符串。这个属性类似于DHTML中的ID属性。
lightWeight
可选。指定HTC文件是否包含标签的字符串。如果HTC文件不包含标签,这个属性应当设置为true来改进表现效果。这个属性对任何HTC文件均有效。
true
HTC文件不包含标签,因而无需每次都解析并表现自定义标签。这些标签由HTC文件定义,在主文档中使用。
false
默认值。HTC包含必需解析并表现的自定义标签。这些标签由HTC文件定义,在主文档中使用。
literalContent
可选。指定自定义标签包含的内容是被解析并表现,还是作为数据岛处理的字符串。这个属性仅在HTC文件定义一个元素行为时有效,此时需要使用tagName属性。更多信息请查阅备注。
false
默认值。由tagName属性定义的标签内的文本和标签并作为数据岛处理,而是解析并表现。
nested
Internet Explorer 6及后继版本。Content within the first opening and last closing of the tag defined by the tagName attribute is treated as a data island and is not parsed or rendered.更多信息请查阅使用literalContent属性。
true
Content within the first opening and last closing of the tag defined by the tagName attribute is treated as a data island and is not parsed or rendered.
NAME
可选。指定主文档中提交的行为的名称的字符串。
supportEditMode
可选。指定HTC文件内容是否可编辑的字符串。这个属性仅在HTC文件定义一个元素行为时有效。
true
HTC文件包含的标签可编辑。
false
默认值。HTC