CSS display 屬性的重疊覆蓋

2021-09-11 08:24:00 字數 1265 閱讀 8897

原文詳解:css display 屬性的重疊覆蓋

css display屬性,一般為隱藏某個標籤的顯示,

並列n個div或者標籤消除隱藏,

我們需要將某個div展示,某些div隱藏。

js直接控制css變換即可,這樣display=none屬性便可生效。

生效後上面的div樣式便會被顯示的div覆蓋。

"width: 100%;margin-top: -4.5%  "

>

"timeview" style=

"width: 100%;height:460px;text-align: center;"

>

<

%--按時間--

%>

"box" style=

"width: 100%;height: 100%"

>

<

/div>

<

/div>

"productview" style=

"width: 100%;height:460px;text-align: center;"

>

<

%--按型別--

%>

"product" style=

"width: 65%;height: 100%;margin-left: 10%"

>

<

/div>

<

/div>

"yardview" style=

"width: 100%;height:460px;text-align: center;"

>

<

%--按園區(餅圖和柱狀曲線)--

%>

"cityin" style=

"width: 49%;height: 280px;float: left;"

>

<

/div>

"cityout" style=

"width: 49%;height: 280px;float: left;"

>

<

/div>

"citycolumnar" style=

"width: 75%; margin-left: 15%; height: 250px;"

>

<

/div>

<

/div>

<

/div>

以上為開發**,面對開發需求,記錄學習之路。

css display屬性詳解

css display屬性用於指定在頁面上使用哪種盒模型來渲染指定的元素。通俗來講就是某個元素在頁面中的顯示方式 inline table,table,table row group,table column,table column group,table header group,table f...

css display屬性辨析

經常看到這樣的屬性,block inline 也用的比較多,但是什麼讓它們產生的差異,並沒有深究過,inline block 不太明白怎麼回事,今天做乙個小結。block inline就不多說,乙個塊兒級,乙個行級,inline block則是對外表現是行級,包含的元素則表現塊兒級屬性。具體看下邊解...

Css display的幾個屬性

塊級元素 block 特性 總是獨佔一行,表現為另起一行開始,而且其後的元素也必須另起一行顯示 寬度 width 高度 height 內邊距 padding 和外邊距 margin 都可控制 內聯元素 inline 特性 和相鄰的內聯元素在同一行 寬度 width 高度 height 內邊距的top...