Why use definition lists (DL,DD,DT) tags for HTML forms instead of tables?

前端 未结 11 1633
醉酒成梦
醉酒成梦 2020-12-02 06:29

I\'ve come across a few examples recently that do things like:

Full Name:
11条回答
  •  盖世英雄少女心
    2020-12-02 07:00

    Part of the reason for using

    for marking up the form is that it is much easier to do fancy CSS layout tricks with a
    than a . The other part is that it better reflects the semantics of the form (a list of label/field pairs) than a table would.

    Ok, table hate is part of it too.

    提交回复
    热议问题