码迷,mamicode.com
首页 > 其他好文 > 详细

z-index 详解

时间:2016-02-19 10:28:35      阅读:165      评论:0      收藏:0      [点我收藏+]

标签:

Definition and Usage

The z-index property specifies the stack order of an element.

An element with greater stack order is always in front of an element with a lower stack order.

Note: z-index only works on positioned elements (position:absolute, position:relative, or position:fixed).

Model: How is the z-index determined?

1                                          z-index
2 <div id=A>                                Auto 1
3     <div id=B>                            Auto 1.1
4        <div id=C style="z-index:1"></div>          Manual 1
5        <div id=D></div>                   Auto 1.1.2
6     </div>                                
7     <div id=E></div>                      Auto 1.2
8 </div>
9 <div id=F></div>                          Auto 2

 

z-index 详解

标签:

原文地址:http://www.cnblogs.com/hzj680539/p/5200001.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!