Photograph of Llibreria bookstore, Amsterdam, the Netherlands

The majority of web content today exists in a state of retrograde amnesia. Created in a moment, content is constantly altered, retaining no memory of its past state. This deletion of history is lightyears away from the original conception of the web by Vannear Bush and Ted Nelson: as it exists today, publishing on the web is more akin to the Soviet politburo’s airbrushing of history.

Obsessed with the ever-flowing present, this process of constant recreation removes memory from the Internet: corrections, the development of ideas, millions of conversations, all disappear into the singularity. The exceptions are rare and limited: the documented editing process at Wikipedia, the Library of Congress’ archival of Twitter, various forums, and the efforts of curators like Jason Scott Lee and the team at archive.org. Developers should be more responsible net citizens, proactively archiving their own content for prosperity.

has supported a basic content editing history system for a long time, with a significant feature added in HTML5. Content that has been redacted from within a previously published document should be marked up with the del tag:

<p>This unchanged content was part of the original document.
<del>This sentence was also original content, which has now been redacted</del>

Most browsers will display <del> content as strikethrough, although we can change that with CSS, including the option to hide <del> content entirely.

This unchanged content was part of the original document. This sentence was also original content, which has now been redacted

XHTML lacked any context for del, but in HTML5 we can add a timestamp for the moment the content was removed through the datetime attribute:

<p>This unchanged content was part of the original document.
<del datetime="2013-02-03T00:00Z">This was also original content, 
which has now been redacted</del>

In the example above the attribute defines the day of deletion; datetime values can be accurate down to the minute, second, and timezone.

Material inserted after original publication should be marked up with <ins>. Again, HTML5 adds the option of including the datetime attribute to show search engines and the browser when the new content was added:

<p> This unchanged content was part of the original document.
<ins datetime="2013-02-8T00:00Z">This is new content</ins>.

Content marked up as <ins>. is visually displayed as underlined in the browser; again, we can change that to whatever we want with CSS.

This unchanged content was part of the original document.This is new content.

The <ins> and <del> tags can also take a cite attribute, which can lead the browser and reader to a further explanation for the insertion or deletion:

<p> This unchanged content was part of the original document.
<ins datetime="2013-02-8T00:00Z" cite="http://accurate.com/insertion#reason">This is new content</ins>.

The new datetime feature for ins and del means that it is possible to do several things, if we add the right code:

  • Explore a document’s editing history inline in the browser.
  • Highlight new additions and fade deletions of content over time.
  • Display information related to the content currently being read.

By adding HTML5’s arbitrary data attribute, it would also be possible to expand the context of a deletion or insertion as added metadata:

<p> This unchanged content was part of the original document.
<ins datetime="2013-02-8T00:00Z" data-deletedBy="Jeff Koons" 
data-deleted-reason="Incorrect information">This is old content</ins>.

Sadly, no CMS currently supports these kinds of features, but it is entirely possible to handcode the same functionality into your pages, which I will demonstrate in upcoming articles.

Photograph of Llibreria bookstore, Amsterdam, the Netherlands, by MorBCN

Enjoy this piece? I invite you to follow me at twitter.com/dudleystorey to learn more.