Posted By

picale on 03/13/08


Tagged

form


Versions (?)

Who likes this?

11 people have marked this snippet as a favorite

arala22
Baris
SpinZ
gbot
mrjthethird
SmpleJohn
juke
asturi
amasters
satsuma
vodou


Tableless forms


 / Published in: CSS
 

  1. <form>
  2. <label for=”name”>Name</label>
  3. <input id=”name” name=”name”><br>
  4. <label for=”address”>Address</label>
  5. <input id=”address” name=”address”><br>
  6. <label for=”city”>City</label>
  7. <input id=”city” name=”city”><br>
  8. </form>
  9.  
  10. label,input {
  11. display: block;
  12. width: 150px;
  13. float: left;
  14. margin-bottom: 10px;
  15. }
  16.  
  17. label {
  18. text-align: right;
  19. width: 75px;
  20. padding-right: 20px;
  21. }
  22.  
  23. br {
  24. clear: left;
  25. }

Report this snippet  

Comments

RSS Icon Subscribe to comments
Posted By: SmpleJohn on May 6, 2008

Wow, I feel like an idiot right about... now. This is so easy, thanks.

You need to login to post a comment.