visibility | NN 4 IE 4 CSS 2
| Inherited: Yes
Controls whether the element is rendered on the page. An element hidden via the visibility attribute preserves space in the document where the element normally appears. If you prefer surrounding content to cinch up the space left by a hidden element, see the display attribute. The CSS specification suggests that the value of collapse, when applied to table row-related elements, should cinch up the table, but no mainstream browser does that yet.

The visibility attribute is inherited when its value is set to inherit. This setting means that if the parent is hidden, the child is also hidden. But, by setting the child's visibility attribute to visible, you can still keep the parent hidden while showing the child independently.

CSS Syntax
    visibility: visibilityType
Value
One of the constant values: collapse | hidden | inherit | visible. IE for Windows does not recognize the collapse value. Navigator 4 allows visibility only of positioned elements.
Initial Value
visible
Example
    #congrats {visibility: hidden}
Applies To
All elements.
Object Model Reference
    [window.]document.getElementById("elementID").style.visibility