Hi all,
What happens because of the following code?
margin:1em 0;
I know the margin is set to 1em. But what happens because of the 0 after the 1em?
Macamba
hi, wen you say margin 1em
hi,
wen you say margin 1em 0; then it means that the top margin is 1em while all the others are zero.
Basically wen you giv margins it goes in the following way... from clockwise, top right bottom left.
mihir
Thanks
Thanks :blushing:
Read up on margin (and other
Read up on margin (and other short cuts) at the w3c css 2.1 spec. Its pretty clear and easy to understand on such things.
mihirc wrote:hi, wen you say
hi,
wen you say margin 1em 0; then it means that the top margin is 1em while all the others are zero.
Basically wen you giv margins it goes in the following way... from clockwise, top right bottom left.
mihir
This is WRONG. As I say in my previous post, read up on the spec. I could repeat it here, but you are better off getting used to referring to it for specific questions like this. fwiw, all current browsers follow the spec on shortcuts.
hi, Thanks for that.... i
hi,
Thanks for that.... i guess i learnt half of it... a addition to my knowledge.
I always, gave it to all 4.
anyways, thanks...
mihir