Title:
|
Expressing Dublin Core in HTML/XHTML meta and link elements |
Creator:
|
Andy
Powell
UKOLN, University of Bath |
Date Issued:
|
2003-11-01
|
Identifier:
|
|
Replaces:
|
|
Is Replaced By:
|
Not applicable
|
Latest Version:
|
|
Status of Document:
|
This is a DCMI Working Draft.
|
Description of Document: | This document describes how Dublin Core metadata can be encoded in HTML/XHTML <meta> elements. |
|
This document describes how a Dublin Core [DCMI] metadata record can be embedded into an HTML/XHTML Web page using HTML/XHTML elements.
It should be noted that several alternative mechanisms are available for associating a DC record with (or embedding a DC record into) an HTML/XHTML [HTML] resource. These include:
These alternative approaches are not described here.
This document uses the following terminology:
Note that Dublin Core metadata elements are properties (as defined above). Note also that there is potential confusion between the HTML/XHTML usage of the terms 'element' and 'attribute' and the usage of those terms in a more general metadata context.
In the context of this document, it should be noted that the resource being described is an HTML/XHTML Web page and the Dublin Core record describing that resource is embedded into it using HTML/XHTML <meta> elements. It is only possible to describe a single resource (the Web page) using this method. To describe multiple resources (for example, multiple images), link to one or more separate XML or RDF/XML documents containing the multiple Dublin Core records.
Metadata should be embedded into the <head> section of an XHTML Web page [XHTML11] using the <meta> and <link> elements, as described here.
Use the 'name' and 'content' attributes of the XHTML <meta> element to encode the DC element (one of the 15 DCMES elements or one of the other elements defined by DCMI, e.g. audience) and its value. Use the following patterns:
<meta name="DC.element" content="Value" /> <meta name="DCTERMS.element" content="Value" />
For example:
<meta name="DC.date" content="2001-07-18" /> <meta name="DCTERMS.audience" content="software developers" />
As a general rule, element names may be mixed-case but should always have a lower-case first letter.
The value in the 'content' attribute is defined to be CDATA, i.e. a sequence of characters from the document character set which may include character entities. Long values may be wrapped across multiple lines as necessary.
Element refinements are also encoded using the 'name' and 'content' attributes of the XHTML <meta> element. Use the following pattern:
<meta name="DCTERMS.elementRefinement" content="Value" />
For example:
<meta name="DCTERMS.modified" content="2001-07-18" />
Element refinements should use the names specified in the DCMI Metadata Terms recommendation (listed as the 'Name', not as the 'Label'). As a general rule, element refinement names may be mixed-case but should always have a lower-case first letter.
Encoding schemes are encoded using the 'scheme' attribute of the XHTML <meta> element, using the following pattern:
<meta name="DC.element" scheme="DCTERMS.Scheme" content="Value" />
For example:
<meta name="DC.date" scheme="DCTERMS.W3CDTF" content="2001-07-18" /> <meta name="DC.type" scheme="DCTERMS.DCMIType" content="Text" />
Encoding schemes should use the names specified in the DCMI Metadata Terms recommendation (listed as the 'Name', not as the 'Label'). As a general rule, encoding scheme names may be mixed-case but should always start with an upper-case letter. Encoding scheme names are often all upper-case.
Where the value of a property is the URI of another resource (as is typically the case with the DC.relation element for example) an alternative form of encoding using the XHTML <link> element is preferred. Use the following pattern:
<link rel="propertyName" href="resourceURI" />
For example:
<link rel="DC.relation" href="http://www.example.org/" /> <link rel="DCTERMS.references" href="http://www.example.org/publications/2002/176459.pdf" />
In some cases it may be appropriate to encode a list of DCMI and other 'Link types' [XHTMLLINK], for example:
<link rel="DC.rights copyright" href="http://www.example.org/rights.html" /> <link rel="DCTERMS.tableOfContents contents" href="http://www.example.org/toc.html" />
Where the language of the value is indicated, it should be encoded using the 'xml:lang' attribute of the XHTML <meta> element and/or the 'hreflang' attribute of the XHTML <link> element. For example:
<meta name="DC.subject" xml:lang="en-GB" content="seafood" /> <meta name="DC.subject" xml:lang="fr" content="fruits de mer" /> <link rel="DC.relation" hreflang="en" href="http://www.example.org/en/" /> <link rel="DC.relation" hreflang="de" href="http://www.example.org/de/" />
Multiple property values should be encoded by repeating the XHTML <meta> element for that property, for example:
<meta name="DC.title" content="First title" /> <meta name="DC.title" content="Second title" />
Note that the order of repeated elements and element refinements is not guaranteed to be preserved across multiple software applications.
The 'DC.' and 'DCTERMS.' prefixes in the property names above are used to indicate the namespace [DCNS] from which the property is taken. The namespace URI should be encoded in the XHTML <link> element [RELSCHEMA], using the following pattern:
<link rel="schema.prefix" href="namespaceURI" />
For example:
<link rel="schema.DC" href="http://purl.org/dc/elements/1.1/" /> <link rel="schema.DCTERMS" href="http://purl.org/dc/terms/" />
While any string is allowable as the prefix, the use of 'DC.' and 'DCTERMS.' is recommended.
In order to give recipient software applications an indication of the XHTML profile that was used to encode the DCMI metadata, the 'profile' attribute of the XHTML <head> element must be used to provide the URI of this DCMI recommendation, as follows:
<head profile="http://dublincore.org/documents/dcq-html/">
Note that previous versions of this document (and other DCMI HTML-encoding documents) made some different recommendations to those found in this document, as follows:
These forms of encoding are acceptable but are no longer considered the preferred form.
In general, any software applications that consume DC records embedded into HTML/XHTML Web pages should ignore the case of DC namespace prefixes, element names and element refinement names. I.e. all the following forms should be treated as being equivalent:
<meta name="DC.date" content="2001-07-18" /> <meta name="DC.Date" content="2001-07-18" /> <meta name="dc.date" content="2001-07-18" />
as should:
<meta name="DC.Date.modified" content="2001-07-18" /> <meta name="DCTERMS.modified" content="2001-07-18" />
and:
<meta name="DC.Date" scheme="W3CDTF" content="2001-07-18" /> <meta name="dc.date" scheme="dcterms.W3CDTF" content="2001-07-18" />
All applications must generate metadata according to the recommendations above.
All the examples in this document conform to XHTML 1.1. The recommendations in this document can be applied to versions of HTML prior to XHTML 1.0 (e.g. HTML 4.01 [HTML401]) but the resulting syntax will be slightly different because older versions of HTML do not require the trailing '/' before the closing '>' in the HTML <meta> and <link> elements. Furthermore, for HTML 4.01 and older versions of HTML, 'lang' should be used to indicate the language of the value, rather than 'xml:lang'. For XHTML 1.0 Transitional (i.e. XHTML designed to be compatible with HTML) both 'lang' and 'xml:lang' should be used, for other version of XHTML (such as 1.1) only xml:lang should be used.
DC metadata can be mixed with non-DC metadata in HTML/XHTML <meta> elements. The following example embeds DC, AGLS [AGLS] and unspecified metadata properties in the same HTML/XHTML Web page:
<link rel="schema.DC" href="http://purl.org/dc/elements/1.1/" /> <link rel="schema.AGLS" href="http://www.naa.gov.au/recordkeeping/gov_online/agls/1.2" /> <meta name="DC.title" content="Services to Government" /> <meta name="AGLS.Function" scheme="AGIFT" content="recordkeeping standards" /> <meta name="keywords" content="archives, information management, public administration" />
Note that DCMI conventions for naming properties and encoding schemes may not apply to non-DC metadata elements.
A qualified DC metadata record for this document is shown below. It can also be found embedded into the <head> section of the HTML source of this Web page.
... <head profile="http://dublincore.org/documents/dcq-html/"> <title>Expressing Dublin Core in HTML/XHTML meta and link elements</title> <link rel="schema.DC" href="http://purl.org/dc/elements/1.1/" /> <link rel="schema.DCTERMS" href="http://purl.org/dc/terms/" /> <meta name="DC.title" lang="en" content="Expressing Dublin Core in HTML/XHTML meta and link elements" /> <meta name="DC.creator" content="Andy Powell, UKOLN, University of Bath" /> <meta name="DCTERMS.issued" scheme="DCTERMS.W3CDTF" content="2003-11-01" /> <meta name="DC.identifier" scheme="DCTERMS.URI" content="http://dublincore.org/documents/dcq-html/" /> <link rel="DCTERMS.replaces" hreflang="en" href="http://dublincore.org/documents/2000/08/15/dcq-html/" /> <meta name="DCTERMS.abstract" content="This document describes how qualified Dublin Core metadata can be encoded in HTML/XHTML <meta> elements" /> <meta name="DC.format" scheme="DCTERMS.IMT" content="text/html" /> <meta name="DC.type" scheme="DCTERMS.DCMIType" content="Text" /> </head> ...
This document is based on existing recommendations for encoding Dublin Core metadata into HTML [RFC2731], the previous version of this document by Simon Cox, Eric Miller and Andy Powell, current practice on the Web and recent versions of the HTML/XHTML specifications.
[DCMI] Dublin Core
Metadata Initiative
http://dublincore.org/
[HTML] HyperText
Markup Language (HTML)
http://www.w3.org/MarkUp/
[DCRDF]
Expressing Simple Dublin Core in RDF/XML
Dave Beckett, Eric Miller, Dan Brickley, 2001
http://dublincore.org/documents/dcmes-xml/
[QDCRDF]
Expressing Qualified Dublin Core in RDF / XML
Stefan Kokkelink, Roland Schwdnzl, 2002
http://dublincore.org/documents/dcq-rdf-xml/
[DCXML]
Guidelines for implementing Dublin Core in XML
Andy Powell, Pete Johnston
http://dublincore.org/documents/dc-xml-guidelines/
[DCMES] Dublin
Core Metadata Element Set, Version 1.1: Reference Description
http://dublincore.org/documents/dces/
[DCTERMS]
DCMI Metadata Terms
http://dublincore.org/documents/dcmi-terms/
[XHTML11]
XHTML 1.1: Module-based XHTML
W3C Recommendation, May 2001
http://www.w3.org/TR/xhtml11
[XHTMLLINK]
The 'link'-Element in (X)HTML
http://www.subotnik.net/html/link
[DCNS] Namespace
Policy for the Dublin Core Metadata Initiative (DCMI)
http://dublincore.org/documents/dcmi-namespace/
[RELSCHEMA] A Proposed Convention for Embedding
Metadata in HTML
http://www.w3.org/Search/9605-Indexing-Workshop/ReportOutcomes/S6Group2.html
[HTML401]
HTML 4.01 Specification
Dave Raggett, Arnaud Le Hors, Ian Jacobs, 1999
http://www.w3.org/TR/html40/
[AGLS]
AGLS Metadata Standard
http://www.naa.gov.au/recordkeeping/gov_online/agls/summary.html
[RFC2731]
Encoding Dublin Core metadata in HTML
John Kunze, 1999
http://www.ietf.org/rfc/rfc2731.txt