Thread Starter
karim
(@karim)
indeed, you define your categories by a list of links :
<dt>Categories</dt>
<dl>
</dl>
Actually, the example given by mark’s link was good:
<dl>
<dt>Vole</dt>
<dd>Small creature related to the weasel</dd>
<dt>Weasel</dt>
<dd>Small creature related to the vole</dd>
</dl>
dl looks like it is supposed to encapsulate all ‘d’ tags, much like ul/ol encapsulate li tags. so, based at least on some of the examples I’ve seen, it’s not really meant to markup the way you used it. it would be nice if there was a ‘lt’ tag for ‘list title’ or something like that, which is what you are going after. But you can style the UL, and override on the LI, or simply put a span around your title.
It would be nice to kick this around and figure out what the appropriate ‘WP standard’ will be going forward, as applying CSS easily to some of the lists (not just WP generated, but even my own custom stuff) can be confusing without a well defined markup.
-d
1539
Perhaps I wasn’t precise enough with my references.
Definition lists are most commonly used in glossary’s and indexes, but can be used anywhere that a short section of text is followed by a longer segment. – source – About : webdesign
This is an ideal way to set up a glossary or list of terms. – source – XHTMl user guide
Or you can go straight to the definitive source…
Definition lists vary only slightly from other types of lists in that list items consist of two parts: a term and a description. – source – W3C
In the sense of writing the code, you are defining categories, but you are not literally defining them.
The <nl> tag looks nice.
Anonymous
There was a discussion over at SimpleBits a while back about this exact same thing.
http://www.simplebits.com/bits/simplequiz/#entry550
And another discussion very similar to the above but this time with numbered list pairs
http://www.simplebits.com/bits/simplequiz/#entry673
I hope this helps.
Anonymous
BTW what happened to the font in this thread? Someone forgot the close a [/code] tag methinks