Posted By

thesmu on 07/21/09


Tagged

margin border padding order


Versions (?)

border / margin / padding etc.. shorthand order


 / Published in: CSS
 

URL: http://www.w3schools.com/css/css_border.asp

TRouBLe

T - op R - ight o u B - ottom L - eft e

  1. p
  2. {
  3. border-top-style:dotted;
  4. border-right-style:solid;
  5. border-bottom-style:dotted;
  6. border-left-style:solid;
  7. }
  8.  
  9.  
  10.  
  11.  
  12. The margin property can have from one to four values.
  13.  
  14. * margin:25px 50px 75px 100px;
  15. o top margin is 25px
  16. o right margin is 50px
  17. o bottom margin is 75px
  18. o left margin is 100px
  19.  
  20. * margin:25px 50px 75px;
  21. o top margin is 25px
  22. o right and left margins are 50px
  23. o bottom margin is 75px
  24.  
  25. * margin:25px 50px;
  26. o top and bottom margins are 25px
  27. o right and left margins are 50px
  28.  
  29. * margin:25px;
  30. o all four margins are 25px

Report this snippet  

You need to login to post a comment.