3 replies [Last post]
Verschwindende
Verschwindende's picture
Offline
Guru
Last seen: 3 weeks 2 days ago
Timezone: GMT-4
Joined: 2009-10-09
Posts: 2037
Points: 2259

I got into a conversation about LABELs and INPUTs being put into an unordered list. I thought the idea was a bit nutty myself. Is there any logical/semantical sense to using LIs to surround LABELS/INPUT pairs?

Tony
Tony's picture
Offline
Moderator
Brisbane
Last seen: 5 hours 54 min ago
Brisbane
Timezone: GMT+10
Joined: 2003-03-12
Posts: 5125
Points: 2722

Hi Verschwindende, I remember

Hi Verschwindende,
I remember long ago looking at this and even looking at DL's as containers for form elements, which I think may be more semantically correct then UL.
Really form elements have enough semantic meaning on their own and gain nothing from their containers. So I think the common practice of using DIV's to help layout forms is the best way to go.

Have a Merry Christmas, I'm about to disappear for a few days camping.

Verschwindende
Verschwindende's picture
Offline
Guru
Last seen: 3 weeks 2 days ago
Timezone: GMT-4
Joined: 2009-10-09
Posts: 2037
Points: 2259

Thanks Tony! Yeah, that's

Thanks Tony! Smile

Yeah, that's what I'm thinking. Actually, I rarely even use DIVs.

Hugo
Hugo's picture
Offline
Moderator
London
Last seen: 1 week 18 hours ago
London
Timezone: GMT+1
Joined: 2004-06-06
Posts: 15664
Points: 2802

The most I'll ever use

The most I'll ever use outside of the available form elements such as fieldset tends to be paragraph tags to wrap label/input pairs just for a little extra control, but in all honesty they're not that necessary or could be divs equally.

Before you make your first post it is vital that you READ THE POSTING GUIDELINES!
----------------------------------------------------------------
Please post ALL your code - both CSS & HTML - in [code] tags
Please validate and ensure you have included a full Doctype before posting.
Why validate? Read Me