摘要: float:right向下错位,例如 <div>左文字<span style="float:right">右浮动</span></div> 解决办法: 1、将span放到文字前面 <div><span style="float:right">右浮动</span>左文字</div> 2、div{pos 阅读全文
posted @ 2016-05-11 17:06 皓月千里 阅读(1274) 评论(0) 推荐(0)
摘要: 1、min-height: div{min-height:100px;_height:100px} 2、min-width: div{display:inline-block;*display:inline;zoom:1;min-width:100px;_width:100px;white-spac 阅读全文
posted @ 2016-05-11 16:42 皓月千里 阅读(176) 评论(0) 推荐(0)
摘要: 1、<iframe>里的<a>标签跳转,关键在于target: target="_top"跳转到最外一层; target="_parent"跳转到上一层; target="_blank"跳转到新页面; 2、js跳转: window.location.href.location.href 本页面跳转; 阅读全文
posted @ 2016-05-09 14:15 皓月千里 阅读(2070) 评论(0) 推荐(0)
摘要: 无标题文档 阅读全文
posted @ 2016-05-09 10:45 皓月千里 阅读(275) 评论(0) 推荐(0)
摘要: 在使用z-index这个属性之前,我们必须先了解使用z-index的必要条件: 1、要想给元素设置z-index样式,必须先让它变成定位元素,说的明白一点,就是要给元素设置一个postion:relative(定位元素:position属性值设置除默认值static以外的元素,包括relative, 阅读全文
posted @ 2016-05-05 14:52 皓月千里 阅读(227) 评论(0) 推荐(0)
摘要: <input type="checkbox" checked ='checked'/> js控制checkbox是否选中的代码:function check() { document.getElementById("check1").checked=true }function uncheck() 阅读全文
posted @ 2016-04-16 09:14 皓月千里 阅读(2065) 评论(0) 推荐(0)
摘要: 使用酷播迷你 CuPlayerMiniV4.1 版播放器: html代码如下: 阅读全文
posted @ 2016-04-15 09:37 皓月千里 阅读(243) 评论(0) 推荐(0)
摘要: 外边距重叠是指,若两个元素上下毗邻且都定义了不为0的外边距值,同时又没有任何内边距、边框等设定,那么这两个元素之间的距离将小于二者外边距的和。因此,两个都带有20px外边距的元素垂直相接并不会显示出40px的缝隙——两个外边距会重叠在一起,最终元素之间的距离只有20px。 另外,重叠效果将同时作用于 阅读全文
posted @ 2016-04-13 17:06 皓月千里 阅读(247) 评论(0) 推荐(0)
摘要: 1.丢弃小数部分,保留整数部分parseInt(5/2) 2.向上取整,有小数就整数部分加1 Math.ceil(5/2) 3,四舍五入. Math.round(5/2) 4,向下取整 Math.floor(5/2) Math 对象的方法FF: Firefox, N: Netscape, IE: I 阅读全文
posted @ 2016-04-13 13:40 皓月千里 阅读(658) 评论(0) 推荐(0)
摘要: 一、list-style-type属性 list-style-type属性是用来定义li列表的项目符号的,即列表前面的修饰。list-style-type属性是一个可继承的属性。其语法结构如下:(列举一些常用的属性值) list-style-type:none/disc/circle/square/ 阅读全文
posted @ 2016-04-12 15:53 皓月千里 阅读(3694) 评论(0) 推荐(0)