The CSS rules visibility:hidden
and display:none
both result in the element not being visible. Are these synonyms?
With visibility:hidden
the object still takes up vertical height on the page. With display:none
it is completely removed. If you have text beneath an image and you do display:none
, that text will shift up to fill the space where the image was. If you do visibility:hidden the text will remain in the same location.