« Barbarism revisited | Main | Semantics in HTML »

January 08, 2007

Built in Semantics in HTML

I've been working on some things to do with semantics on the web, in particular in relation to HTML. As part of this, I've put together a list of all the elements and attributes of HTML that I consider have strong semantics ass ociated with them. I'd be interested in people's thoughts - any missing? Any of these not really "semantic"?

Thanks for your thoughts,


p.s. this will be published permantently online, as will the article I'm working on.

This is a rough and ready analysis of the built in semantics of HTML. I've left out the semantics of tables and their associated elements and attributes, as these are specific to one kind of markup (tabular data), as opposed to markup more generally. It by no means implies that such markup is not "semantic" (when used appropriately it of course is). Similarly, markup for forms is excluded, and again, of course this markup is semantic when used appropriately. I've also excluded deprecated elements and attributes, regardless of whether they are semantic or presentational. In addition, I've left out included (or "replaced" content (such as object, and img)). My reasoning here is that these are not so much for marking up content, and "transcluding" it from elsewhere.


Each A element defines an anchor
Indicates an abbreviated form
Indicates an acronym
The ADDRESS element may be used by authors to supply contact information for a document or a major part of a document such as a form
BLOCKQUOTE is for long quotations (block-level content)
Contains a citation or a reference to other sources
Designates a fragment of computer code


Indicates that this is the defining instance of the enclosed term

div, span

The DIV and SPAN elements, in conjunction with the id and class attributes, offer a generic mechanism for adding structure to documents

dl, dd, dt

Definition lists, created using the DL element, generally consist of a series of term/definition pairs (although definition lists may have other applications). The term is given by the DT element and is restricted to inline content. The description is given with a DD element that contains block-level content

del, ins

INS and DEL are used to markup sections of the document that have been inserted or deleted with respect to a different version of a document

Indicates emphasis

h1 .. h6

A heading element briefly describes the topic of the section it introduces


Indicates text to be entered by the user

ul, ol, li

unordered and ordered lists are in fact not defined in the specification. "Lists may contain: Unordered information. Ordered information. Definitions."


The P element represents a paragraph


Q is intended for short quotations (inline content) that don't require paragraph breaks


Designates sample output from programs, scripts, etc


Indicates stronger emphasis


Indicates an instance of a variable or program argument


For user agents that cannot display images, forms, or applets, this attribute specifies alternate text
This attribute assigns a class name or set of class names to an element ... For general purpose processing by user agents
The value of this attribute is a URI that designates a source document or message. This attribute is intended to point to information explaining why a document was changed.
The value of this attribute is a URI that designates a source document or message. This attribute is intended to give information about the source from which the quotation was borrowed
The value of this attribute specifies the date and time when the change was made
The id attribute assigns a unique identifier to an element ... For general purpose processing by user agents
This attribute specifies the base language of an element's attribute values and text content
This attribute specifies a link to a long description of the image
This attribute describes the relationship from the current document to the anchor specified by the href attribute
This attribute is used to describe a reverse link from the anchor specified by the href attribute to the current document
This attribute offers advisory

information about the element for which it is set

January 8, 2007 | Permalink


TrackBack URL for this entry:

Listed below are links to weblogs that reference Built in Semantics in HTML:


"unordered and ordered lists are in fact not defined in the specification"

Hmm. By my reading, ordered lists are defined: An ordered list, created using the OL element, should contain information where order should be emphasized, as in a recipe; it's just unordered lists that aren't defined.

Posted by: Ben Buchanan | Jan 8, 2007 4:42:48 PM

How about the various elements that appear in head?
eg. title, meta, link & friends, as well as the profile attribute (and possibly xmlns?).

Also the hreflang attribute on a elements.

In certain circumstances I think br / can have semantic meaning as well (poems, etc. - probably a bit of contentious issue though).

Posted by: Lindsay Evans | Jan 8, 2007 5:03:22 PM


what I meant was that the semantics of lists isn't defined. I mean, one the one hand, its pretty obvious what a list is. Yep, good point about ordered lists, I'll pay that - that quaifies as a definition :-) But a lot of it is pretty nebulous - p is a "paragraph" and so on.



Posted by: john Allsopp | Jan 8, 2007 7:04:27 PM


I didn't mention it, but I also exclued head stuff - I think what I am specificaly interested in here is the semantics of visible HTML. But I'm not quite sure about that yet ;-)

In terms of br/, that's just too thorny - in a sense, there is an impled line element, but for poetry, it would probably make sense to have an explicit line element (even docbook isn't have this, afaik, which surprises me).

hreflang - I just thought it was too obscure and I got lazy - you are really on the ball there lindsey ;-)



Posted by: john Allsopp | Jan 8, 2007 7:09:57 PM

HTML is very flexible. Great semantics.

Posted by: celebrity oops | Dec 12, 2009 8:35:46 PM

I think nowadays nobody using HTML, only PHP and AJAX

Posted by: drugs online | Aug 10, 2010 6:22:14 AM

nice post my friend

Posted by: brian adams | Nov 25, 2010 1:24:11 AM

HTML is very flexible. Great semantics...

Posted by: düzce haber | Dec 9, 2010 2:32:19 AM