float position的測试案例
依据<a target=_blank href="http://blog.csdn.net/goodshot/article/details/44348525">http://blog.csdn.net/goodshot/article/details/44348525</a>我的測试
<p>一、</p>
<p>1.Container div is overflow is not seted ,float element is not be envoloped <br><br>
2.And the postion is seted "static" which means it is not affluncented by the css top and left ect.
<br><br>
3.According to this example,we can see the "float" css attribute is only set the element in the 0 z-index layer. </p>
<div style="background-color:#CCC;;" > <div style="width:100px;height:100px; background-color:blue; "></div> <div style="width:100px;height:100px; background-color:olive; float:left; margin-left:30px"></div>
</div>
二、<br>
<br>
1.Container div is overflow seted ,float element is be envoloped
<div style="background-color:#CCC;; overflow:auto" >
<div style="width:100px;height:100px; background-color:olive; float:left; margin-left:30px; margin-top:20px">2.this is means masked.in the 0 z-index layer.</div> <div style="width:100px;height:100px; background-color:blue; ">2. The static position is the default postion option,then this blue div is not affected by the "top" "left" ect. attributes ,the we can see it is located in the initial position. </div> </div>
以下的截图是在FF中的
三、use "box-set"( always named "clearfix" in chinese "万能闭合")
<br>
<br> <div style="background-color:#696;overflow:auto; " class="box-set" >
<div style="width:100px;height:100px;background-color:#0FF; float:left; margin-top:100px; margin-left:1000px;">
</div>
<br>
<br>
watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvR29vZFNob3Q=/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/dissolve/70/gravity/Center">
四、parent div used css class "box-set" or "overflow:auto" can't affect the div in it. position method float doesn't work in this way .Only margin-left or margin-top can locate the div in float way.
<div style="background-color:#696;overflow:auto; " class="box-set">
<div style="position:absolute; left:200px ; top:120px ; width:100px ; height:100px; background-color:#69F"></div>
<div style="position:float; left:200px ; top:200px ; width:100px ; height:100px; background-color:#69F"></div>
</div>
float position的測试案例的更多相关文章
- Android 平台 HTTP网速測试 案例 API 分析
作者 : 万境绝尘 转载请注明出处 : http://blog.csdn.net/shulianghan/article/details/25996817 工信部规定的网速測试标准 : 除普通网页測速 ...
- 【Android 应用开发】Android 平台 HTTP网速測试 案例 API 分析
作者 : 万境绝尘 转载请注明出处 : http://blog.csdn.net/shulianghan/article/details/25996817 工信部规定的网速測试标准 : 除普通网页測速 ...
- Google开源单元測试框架Google Test:VS2012 配置
由题目可知,Google Test(简称gtest)是Google公布的一个开源C/C++測试框架,被应用于多个开源项目及Google内部项目中,包括Chrome浏览器.LLVM编译器架构.Proto ...
- Robot Framework自己主动化測试框架之我见
一些自己主动化測试现状: 盲目的去做自己主动化,终于以失败告终. 觉得是能提高效率的事情.却推广不下去: 事实上上述问题产生的原因是: 自己主动化測试案例稳定性不高,可维护性比較差: 自己主动化測试工 ...
- MySQL Study之--MySQL压力測试工具mysqlslap
MySQL Study之--MySQL压力測试工具mysqlslap 一.Mysqlslap介绍 mysqlslap是MySQL5.1之后自带的benchmark基准測试工具,类似Apache ...
- 玩转单元測试之DBUnit
本文同一时候发表在:http://www.cnblogs.com/wade-xu/p/4547381.html DBunit 是一种扩展于JUnit的数据库驱动測试框架,它使数据库在測试过程之间处于一 ...
- jsfiddle在线測试Html、CSS、JavaScript——http://jsfiddle.net/
jsfiddle在线測试Html.CSS.JavaScript,并展示測试结果 1.选择jQuery1.9.1 2.选择jQuery UI 1.9.2 3.Html <ul id="n ...
- 沧海一声笑,移动应用的CRASH原因我找到! --记最新款数字化測试“星云測试“的使用攻略
沧海一声笑,移动应用的CRASH原因我找到! --记最新款数字化測试"星云測试"的使用攻略 世界进步那么快,非常多新奇的点子层出不穷,于是我们创业.我们做最酷的手机应用,做最轰炸的 ...
- SWTBOK測试实践系列(4) -- 软件測试技术的黑白之道
白盒測试和黑盒測试往往是项目中最受争议的两种測试类型,每一个人偏爱各不同.现实生活中行业人员大多喜欢白盒測试而忽视黑盒測试,那么项目中又应该怎样平衡这两类測试呢?我们先来看两个案例. 案例一: 某移动 ...
随机推荐
- Java设计模式---工厂模式(简单工厂、工厂方法、抽象工厂)
工厂模式:主要用来实例化有共同接口的类,工厂模式可以动态决定应该实例化那一个类.工厂模式的形态工厂模式主要用一下几种形态:1:简单工厂(Simple Factory).2:工厂方法(Factory M ...
- Oracle 11g 完全卸载
停止所有Oracle 11g相关的服务 1.打开"服务"窗口 键入命令:"services.msc",回车,如下图: 2.停止所有Oracle 11g相关的服务 ...
- 【iOS之runtime、runloop】
什么是runtime runtime就是运行时,是系统在运行时的一些动态机制,它是一套底层的API,我们平时编写的OC代码,最终会转换为runtime实现. runtime的作用 可以利用runtim ...
- Linux命令 rpm
rpm -q samba --查询程序是否安装rpm -qa | grep httpd --[搜索指定rpm包是否安装] --all搜索*http ...
- c - 每位数字尾部加空格
/* input:一个4位整数. output:每位整数后紧跟一个空格的字符串. */ char * insert(char *s) { int len = strlen(s); * len + ); ...
- Oracle除去换行符的方法
Oracle除去换行符的方法 很多数据存进数据库后,可能需要将整条数据取出,并用特殊 符号分割,而且整条数据必须是处于一行,如此,如果数据出现 换行的情况,那么读取时就有问题. 这个时候就 ...
- 3种创建、调用JavaScript对象的方法
hey you guys,两个月没有写技术博客了.作为一名有理想.有抱负的程序员,两个月不写技术博客,真该打.业精于勤,荒于嬉.行成于思,毁于随.勤奋是必不可少的,今后养成一周至少一篇博客的习惯.好了 ...
- 常用mysql笔记
1.insert into ... values insert into tables (col1,col2) values (1,2),(2,3); 2.insert into ... select ...
- poj 1182 并查集高级应用
C - 是谁站在食物链的顶端 Crawling in process... Crawling failed Time Limit:1000MS Memory Limit:10000KB ...
- 用jQuery与JSONP轻松解决跨域访问的问题【转】
原文地址:http://www.jb51.net/article/46463.htm 好在,有jquery帮忙,跨域问题似乎没那么难缠了.这次也借此机会对跨域问题来给刨根问底,结合实际的开发项目,查阅 ...