I’ve come across a few examples recently that do things like:
<dl> <dt>Full Name:</dt> <dd><input type='text' name='fullname'></dd> <dt>Email Address:</dt> <dd><input type='text' name='email'></dd> </dl>
for doing HTML forms. Why is that? What is the advantage over using tables?
I guess it’s up to you to determine the semantics, but in my opinion:
Rather than a definition list, form-related properties should be used.
The ‘for’ attribute in the <label> tag should reference the ‘id’ attribute of a <input> tag. Note that when labels are associated with fields, clicking the label will put the associated field in focus.
You can also use tags like <fieldset> to cluster sections of a form together and <legend> to caption a fieldset.