Adding the attributes

Mark Birbeck's picture

To incorporate the attributes a module called rdfa-10-rules.xsd was created, and in it an attribute group was added:

  <xs:attributeGroup name="rdfa.attlist">
    <xs:attribute name="about" type="CurieOrURI"/>
    <xs:attribute name="content" type="xs:string" />
    <xs:attribute name="datatype" type="Curie"/>
    <xs:attribute name="href" type="CurieOrURI"/>
    <xs:attribute name="property" type="Curie"/>
    <xs:attribute name="rel" type="CurieOrLinkTypeList"/>
    <xs:attribute name="rev" type="CurieOrLinkTypeList"/>
  </xs:attributeGroup>

All of the data types listed here are included in the same module, and discussed in the next section. (They will however, be broken out into a separate 'types' document.)

As you saw in the previous section, some of the attributes that XHTML uses are not here--more XHTML-specific attributes have been kept back in the XHTML driver file.

To make use of these RDFa attributes we simply need to redefine Common.extra:

  <xs:attributeGroup name="Common.extra">
    <xs:attributeGroup ref="Common.extra"/>
    <xs:attributeGroup ref="rdfa.attlist" />
    <xs:attribute name="charset" type="xh11d:Charset"/>
    <xs:attribute name="hreftype" type="xh11d:ContentType"/>
    <xs:attribute name="hreflang" type="xh11d:LanguageCode"/>
    <xs:attribute name="http-equiv" type="xs:NMTOKEN"/>
  </xs:attributeGroup>

Common.extra is an empty definition in XHTML M12N but is part of Common.attribs which is applied to every element.

Note that hreftype is used here instead of type since otherwise there would be a conflict. This is the name proposed in XHTML 2.0.

AttachmentSize
rdfa-10-rules.xsd2.5 KB