Ordered List, I give up.

I have known about the problem for a while now, but today I had to make my decision on where I stand. Whether to use the html list attributes ‘start’ and ‘value’ or not.

I don’t tend to use ordered list that much, in fact I hardly encounter them. Maybe in the back of my mind I knew that there was something very fishy about them and walked around them like it was the scene of a crime.
At the moment I’m building a website that needs to adhere to Dutch government guidelines for authoring websites. All front-end code and its construction are held to a higher standard. It’s Great fun; it also requires a lot of double-checking though.

So when it came time for me to construct a search results page, which basically is a list of results in order of relevance to the search phrase. The design requires that it be numbered and be spread over a number of pages with a set number of results per page.
The ‘numbered’ part begs for an ordered list. What else could it be?
The pagination part is a list of page numbers in an unordered list. The list doesn’t require it to be numbered its content already is. The results list itself should be part of a single continuous numbered list spread over the result pages. The list numbering should reflect this, and here is where the wheels start to come off.

W3C’s recommendation for HTML 4.0 states that the attributes for start and value are deprecated. This is nothing new and hasn’t caused much of a ruckus other than some head scratching and bewilderment.

Why oh why have these attributes been deprecated? To me they seem semantic enough, part of the content structure even. They are certainly not presentational. Some suggest that the deprecation of these attributes is now to be handled by style sheets. This to me is completely idiotic. CSS by its nature is static, the ‘start’ and ‘value’ attributes are dynamic and are effectively driven by the back-end. You have no idea at which value the numbering should be initiated.

The current CSS solution offers no real substitute for ‘start’ the counter-increment can be jerry-rigged to fit the bill for ‘value’ and that’s about it. The CSS solution does allow for more complex numbering. However, this whole CSS lists numbering thing is a pure academic exercise. The CSS solution doesn’t work, at least not in the real world.

Building ordered lists by adding you own numbering and removing the default generated one seems to be a waste of time and certainly more complex to maintain. So I’m sticking with these handy crossbrowser attributes with transitional doctypes until a real, viable and sustainable solution presents itself.

I knew there was a reason I no longer use strict doctypes!

Next entry: A real keyboard
Previous entry: Don’t touch my screen!