Best practice for form layout in html — table or flow?

后端 未结 5 1081
攒了一身酷
攒了一身酷 2021-02-15 23:08

What is considered the best practice for laying out forms in html? Specifically where you have a set of fields with labels, and possible error indicators. The best I can do is u

5条回答
  •  南旧
    南旧 (楼主)
    2021-02-15 23:57

    One can argue a form is tabular data, so a table is acceptable. As David states, they main issue is that you want to use proper LABEL tags.

    In your example, I'm not sure what you gain from using a table over CSS, though.

提交回复
热议问题