我正在做的假设是您试图通过显示其不同的内容模型来定义标签。首先,通过接收文本,你必须将其内容定义为混合。从那里,你可以使用重复的选择,列出了所有其他元素,如IMG,B,G1,G2等
我显示从XHTML XSD的摘录:
<xs:element name="p">
<xs:complexType mixed="true">
<xs:complexContent>
<xs:extension base="Inline">
<xs:attributeGroup ref="attrs" />
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
<xs:complexType name="Inline" mixed="true">
<xs:annotation>
<xs:documentation>
"Inline" covers inline or "text-level" elements
</xs:documentation>
</xs:annotation>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:group ref="inline" />
<xs:group ref="misc.inline" />
</xs:choice>
</xs:complexType>
等。
一个很好的学习可能是看看XTHML XSD。您可以使用XSD编辑器来调查与标签关联的结构。
这就是我一直在寻找的!谢谢。 – Harini 2012-04-05 06:05:15