Profile for rel, rev and class attribute

To markup relations and hierarchies of topics it is necessary to add this information to the links that bind together these single pieces of information. These names presented here are meant as attribute properties for the rel and class attribute, but most of all for the rev attribute.

This document is a metadata profile in the sense of the HTML specification, in section 7.4.4.3 Meta data profiles, as refined by XMDP.


subtopicOf

The topic of this resource is a subtopic of the resource pointed to by the link if used with the rev attribute. Example:

html lang="en" head titleWinter/title link rev="subtopicOf" href="/season.html" title="season" /head body Winter is one of the a rev="subtopicOf" href="/season.html" title="Season"season/as. /body /html

This shows a short html page about the topic "winter", which is a subtopic of "season". The topic name of the current page is one of (in descending order):

  1. The title of the page (the content of the title element)
  2. Any heading in the page whth the ID of "DC.subject"
  3. The first highest-level heading
  4. The file name
  5. The domain name. Exactly: The lowest level part of the domain.

The name of the parent topic, to which the link points to, is one of (in descending order):

  1. The title of the target page
  2. Any heading in the target page whth the ID of "DC.subject"
  3. The first highest-level heading in the target page
  4. The file name of the target page
  5. The target domain name. Exactly: The lowest level part of the domain.
  6. If the link additionally has the rel attribute value of "tag", then the name may be the last part of the path of the link, as specified by the microformats.
  7. The title attribute of the link
  8. The content of the link

The usage of the rel and rev attributes need some clarification:

  • rel

    Using rel="subtopicOf" means, that the target is a subtopic of the current page. This may be used when applyng a top-down approach on structuring information.
  • rev

    Using rev="subtopicOf" means that the current resource is a subtopic of the target page. This may be used on a bottom-up approach.
sameAs

Specifies another writing or a synonym or an abbreviation or, if the current topic is the abbreviation, the full format, or the same topic in another language or the same topic presented in another format. If used with links, other languages are referenced by the hreflang attribute, other formats by the type attribute. If used with other elements, other languages are declared with the lang attribute (for html) or the xml:lang attribute (for xhtml):

Since this property is bidirectional it is possible to use it with the rel attribute as well as with the rev attribute. To be precise, using "rel" means something like "that is the same as this", where "rev" means "this is the same as that". The difference is very esoteric and of nearly no importance. It is possible too to use this as a property of the class attribute.

Assuming the topic of the current page beeing about "regular expression", then these examples may help:

a rel="sameAs" title="regexp" hreflang="de"Reguläre Ausdrücke/a

This links to a page with the same topic but in german language. Further it sets the name of the topic to regexp.

Regular expressions, or, for short, regexp, ...

This sets the content of the abbr container to a synonym for the current topic, without linking to another page.

General