Past HTML, Future HTML?

by Jens Oliver Meiert published on

Consider the following HTML document:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 1996-01//EN">
<html>
<head>
<title></title>
</head>
<body>
<p class="Author">
<h1></h1>
<P>
<P>
<H2></H2>
<P>
<UL>
<LI>
<LI>
<LI>
</UL>
<P>
<!-- … -->
</body>
</html>

You will notice a few things:

  • The unusual doctype
  • The inconsistencies in element case (most notably, <p> vs. <P>)
  • The inconsistencies in omitting optional tags (like dropping </p> and </li> end tags, but keeping </body> and </html>)

Yet in some respects, this document structure is better than the code we find on many modern websites (and that is sites, not even apps).

Why? What’s to like about this kind of code?

  1. It’s valid. If you run this and the respective original page’s code through an HTML conformance checker like the W3C markup validator, the code will validate. This is basic professional work that we don’t see often anymore.

  2. It’s focused. There’s close to no superfluous code. While there’s a little bit more optional markup to be removed, as well as perhaps the Author class, one might rather add code, like the style sheet reference that’s conspicuously missing.

  3. It’s… open-minded. These inconsistencies, they may rub us, and we likely prefer a consistent formatting. But that shouldn’t distract from the fact that the code is valid (which includes uppercase tag names), and that it represents legitimate ways of writing HTML (which in this case means HTML–HTML, and not XHTML–HTML).

So where is this code from? It’s from T.V. Raman’s documentation on style sheets for spoken renderings, published on February 12, 1996. The 1990s and 2000s are behind us in many areas, and yet in some, they may still be ahead:

We could learn from this code and take it into the future, because XHTML–HTML may have long been dead if it wasn’t kept on eternal life support by frameworks and tools that do not use any of the features that HTML (and that is, don’t mind the repetition, HTML–HTML) offers us. The future of HTML—it could embrace more of the HTML of the past.

About Jens Oliver Meiert

Jens Oliver Meiert is a frontend engineering leader and tech author/publisher. He specializes in HTML and CSS optimization and maintainability.

Jens’s Blog: meiert.com
Jens on Mastodon: @j9t@mas.to