make definition list looks like combination of label and input field


/ Published in: CSS
Save to your folder(s)

cross browser
pitfall: fixed width of dt,


Copy this code and paste it in your HTML
  1. dt, dd{
  2. border: 1px red dotted;
  3. display: inline;
  4. }
  5. dt {
  6. clear: left;
  7. float: left;
  8. width: 100px;
  9. }
  10. dd {
  11. display:block;
  12. float: none;
  13. margin-left: 100px;
  14. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.