网络学院 w3pop社区 网络资源 IT新闻

w3pop.com :: 网络学院 :: CSS :: CSS visibility属性

会员登陆

帐号

密码

回答

记住密码

忘记密码? 注册

CSS visibility属性


作者:w3pop.com 翻译/整理:w3pop.com 发布:2007-04-28 浏览:2733 :: ::

The visibility property sets if an element should be visible or invisible.
visibility属性可设置元素为可见还是不可见

Note: Invisible elements takes up space on the page. Use the "display" property to create invisible elements that do not take up space.
注意:不可见的元素会占据页面的空间。可以使用"display"属性来让不可见的元素同时不占据页面的空间

Note: This property is used with scripts to create Dynamic HTML.
注意:这个属性经常在建立动态HTML的时候用到

Inherited: No
继承性:无

Example举例

p
{
visibility: visible
}

Possible Values
可能用到的值

Value 描述
visible The element is visible
元素可见
hidden The element is invisible
元素不可见
collapse When used in table elements, this value removes a row or column, but it does not affect the table layout. The space taken up by the row or column will be available for other content. If this value is used on other elements, it renders as "hidden"
当在表格元素中使用的时候,这个值可以移除一行或是一列,但它不会影响到表格的布局。被行或列所占据的空间对其他内容来说依然是有效的。如果这个值用到别的元素上它所反馈的效果就跟"hidden"一样。

评论 (0) All