I have given margin-bottom:10px; …but still the TEXT’s are at the top . I was expecting them to be 10px above from the bottom. why the bottom-margin is not working ?
float: left shifts to left only . the element does not start from new line right away as a display:block do.
For example, if we add two <p> they are display:block ..because they start in new line right away.
but if we add two <img> inline element with float:left , they just come side by side …they don’t start in new lines , so how come they become a display:block when using float:left ?
Given a width such that the contents fits in it exactly. Images have an intrinsic with so the width of the floated element will be the same as the width of the image in it. For all other contents (like text) you have to supply a width yourself to avoid unexpected results (as is said in the article I linked earlier)