Expression Studio 4.0

Sets whether the content of the object is displayed.


{ visibility: sVisibility }

Possible values


String that specifies one of the following values:


Default. Object inherits the visibility of the next parent object.


Object is hidden.


Object is visible.

The property has a default value of inherit. The cascading style sheet property is not inherited.


Unlike an object with its display property set to none, objects that are hidden using the visibility property still reserve the same physical space in the content layout as they would if they were visible. You can change the visibility through scripting to show and hide overlapping content based on user interaction.


The following example uses the visibility property to determine whether the object is visible. This example uses two calls to an embedded (global) style sheet to hide and then show the image when the user moves the pointer over and then off the text:

    .vis1 {visibility:visible}
    .vis2 {visibility:hidden}
<img id="oSphere" src="sphere.jpg">
<p onmouseover="oSphere.className='vis2'" 
   Move the mouse over this text to make the sphere   

Standards information

This property is defined in Cascading Style Sheets (CSS), Level 2 (CSS2) Ee371214.xtlink_newWindow(en-us,Expression.40).png.

Applies to

a, address, applet, b, big, blockquote, body, button, caption, center, cite, code, col, colgroup, custom, dd, defaults, dfn, div, dl, dt, em, embed, fieldset, form, hn, hr, html, i, iframe, img, input type=button, input type=checkbox, input type=file, input type=image, input type=password, input type=radio, input type=reset, input type=submit, input type=text, li, object, ol, p, s, select, span, sub, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, var, xmp

See also



Send feedback about this topic to Microsoft. © 2011 Microsoft Corporation. All rights reserved.