Margin-left Its Not Working
I'm still a beginner in css, and I'm trying to give some margin-left to my paragraph and
but its not working. I have a div with 700px and I want to give 10px of margin-
Solution 1:
I have a div with 700px and I want to give 10px of margin-left for my
<p>
and<h2>
in relation to the image.But its not working
It is working – you just don’t see it working.
Since your image is floated, that means any inline content will float around it – but the block elements like p and h2 still go over the full width, underneath your image – and that’s why you don’t see any effect of that margin, because it is “under” the image.
Simply give your image a margin-right
of 10px instead. http://jsfiddle.net/2p9vw/4/
Post a Comment for "Margin-left Its Not Working"