This is not an issue i have with css or html, but on the best way to setup a form for semantic purposes. I’ve seen many way to setup forms an i finally started to set them in un-ordered list, but i know some people uses tables, which one is better?
I like to use a definition lists because i see it as users are defining the form fields. The field email is defined to "[email protected]" , the field name to " john doe" etc…. (its hard to explain somehow).
But still, there are a lot of different opinions and solutions about this subject, all of them have their pros and cons.
To use the label tag, simply surround the text that you want associated with a form field with the label tag. If you don’t include the form field inside the label tag, then you should use the for attribute to associate it with the id of the form element you want to label.