About Dublin Core for Drupal

Drupal is an excellent Open Source Content Management System (CMS). One thing that many people have found that it lacks is a means of assigning Dublin Core metadata to its nodes.

Having a requirement for Dublin Core metadata on Drupal sites of my own, I have begun work on a module for Drupal to provide this functionality.

Whereas other metadata modules for Drupal have relied on a field per metadata term, the proposed module stores metadata about nodes as n-tuples, with the metadata terms stored as records in another table. To allow a new metadata term, or even an entire vocabulary, all that is required is the creation of new rows in the appropriate database table.

Some Assumptions

The creation of this module is driven by the needs of myself and a colleague, and its functionality will reflect these needs.

  • The module will be written against Drupal 5.1; if it proves to be back-compatible with other versions, that would be all well and good. No effort, however, will be made to make it so.
  • The database backend is MySQL and makes use of some MySQL-only features. Sorry, I have never even seen PostgreSQL, so it will not be supported. If anyone wants to port it to work with PostgreSQL once the module is finished, I will happily render any such assistance as is required, at least in explaining how my code works.
  • Due to the large number of combined DC and DCTERMS items, the default module will only show the core DC terms plus DCTERMS.created, DCTERMS.modified and DCTERMS.license. This is to stop the node creation page getting too huge, and also to avoid overwhelming beginners with more terms than they will ever require. A minor code change (something along the lines of setting a verbose variable) will, however, present the full set of terms.

What The Module Will Provide

The Dublin Core for Drupal module will provide:

  1. A means to edit and create per-node metadata
  2. (Possible feature) Per-user defaults for the likes of DC.creator, DC.rights and DCTERMS.license
  3. The ability to have multiple instances of an element, provided that each instance has a different lang (language) property.
  4. A function which can be inserted into the <head></head> part of the themes page.tpl.php which will render:
    • Dublin Core metadata elements
    • Links to schemes
    • "Legacy" metadata elements keywords and description, converted from DC.subject and DC.description, on-the-fly (if required).
    • A relative link to a license URI, if a value of DCTERMS.license is present.