Home > Web Front-end > HTML Tutorial > [CSS]-Element hiding (whether it occupies space, the stone is clickable)_html/css_WEB-ITnose

[CSS]-Element hiding (whether it occupies space, the stone is clickable)_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:43:51
Original
1765 people have browsed it

In CSS, there are many ways to hide elements (invisible to the naked eye within the screen). Some occupy space, some do not occupy space; some can respond to clicks, and some cannot. Click.

{ display: none; /* 不占据空间,无法点击 */ }{ visibility: hidden; /* 占据空间,无法点击 */ }{ position: absolute; top: -999em; /* 不占据空间,无法点击 */ }{ position: relative; top: -999em; /* 占据空间,无法点击 */ }{ position: absolute; visibility: hidden; /* 不占据空间,无法点击 */ }{ height: 0; overflow: hidden; /* 不占据空间,无法点击 */ }{ opacity: 0; filter:Alpha(opacity=0); /* 占据空间,可以点击 */ }{ position: absolute; opacity: 0; filter:Alpha(opacity=0); /* 不占据空间,可以点击 */ }{   zoom: 0.001;   -moz-transform: scale(0);   -webkit-transform: scale(0);   -o-transform: scale(0);   transform: scale(0);  /* IE6/IE7/IE9不占据空间,IE8/FireFox/Chrome/Opera占据空间。都无法点击 */}{   position: absolute;   zoom: 0.001;   -moz-transform: scale(0);   -webkit-transform: scale(0);   -o-transform: scale(0);   transform: scale(0);  /* 不占据空间,无法点击 */}
Copy after login

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template