CSS带箭头的DIV方框,自适应高度
2015-06-16 13:25
761 查看
<html>
<head>
<title>CSS实现带箭头的DIV方框</title>
<style>
s{
position:absolute;
top:-20px;
*top:-22px;
left:20px;
display:block;
height:0;
width:0;
font-size: 0;
line-height: 0;
border-color:transparent transparent #666 transparent;
border-style:dashed dashed solid dashed;
border-width:10px;
}
div.container{position:absolute;
top:30px;
left:40px;
font-size: 9pt;
display:block;
height:100px;
width:200px;
background-color:transparent;
*border:1px solid #666;
}
i{position:absolute;
top:-9px;
*top:-9px;
left:-10px;
display:block;
height:0;
width:0;
font-size: 0;
line-height: 0;
border-color:transparent transparent #fff transparent;
border-style:dashed dashed solid dashed;
border-width:10px;
}
.content{
border:1px solid #666;
-moz-border-radius:3px;
-webkit-border-radius:3px;
position:absolute;
background-color:#fff;
width:100%;
height:100%;
padding:5px;
*top:-2px;
*border-top:1px solid #666;
*border-top:1px solid #666;
*border-left:none;
*border-right:none;
*height:102px;
box-shadow: 3px 3px 4px #999;
-moz-box-shadow: 3px 3px 4px #999;
-webkit-box-shadow: 3px 3px 4px #999;
//兼容性,考虑6及之前版本的表现
filter: progid:DXImageTransform.Microsoft.Shadow(Strength=4, Direction=135, Color='#999999');
/* For IE 8 */
-ms-filter: "progid:DXImageTransform.Microsoft.Shadow(Strength=4, Direction=135, Color='#999999')";
}
</style>
</head>
<body>
<div><A href="http://www.999jiujiu.com/">http://www.999jiujiu.com/</A></div>
<div class="container">
<div class="content"><br>CSS实现箭头的边框,我觉得还行吧^_^</div>
<s>
<i></i>
</s>
</div>
<br />
</body>
</html>
<head>
<title>CSS实现带箭头的DIV方框</title>
<style>
s{
position:absolute;
top:-20px;
*top:-22px;
left:20px;
display:block;
height:0;
width:0;
font-size: 0;
line-height: 0;
border-color:transparent transparent #666 transparent;
border-style:dashed dashed solid dashed;
border-width:10px;
}
div.container{position:absolute;
top:30px;
left:40px;
font-size: 9pt;
display:block;
height:100px;
width:200px;
background-color:transparent;
*border:1px solid #666;
}
i{position:absolute;
top:-9px;
*top:-9px;
left:-10px;
display:block;
height:0;
width:0;
font-size: 0;
line-height: 0;
border-color:transparent transparent #fff transparent;
border-style:dashed dashed solid dashed;
border-width:10px;
}
.content{
border:1px solid #666;
-moz-border-radius:3px;
-webkit-border-radius:3px;
position:absolute;
background-color:#fff;
width:100%;
height:100%;
padding:5px;
*top:-2px;
*border-top:1px solid #666;
*border-top:1px solid #666;
*border-left:none;
*border-right:none;
*height:102px;
box-shadow: 3px 3px 4px #999;
-moz-box-shadow: 3px 3px 4px #999;
-webkit-box-shadow: 3px 3px 4px #999;
//兼容性,考虑6及之前版本的表现
filter: progid:DXImageTransform.Microsoft.Shadow(Strength=4, Direction=135, Color='#999999');
/* For IE 8 */
-ms-filter: "progid:DXImageTransform.Microsoft.Shadow(Strength=4, Direction=135, Color='#999999')";
}
</style>
</head>
<body>
<div><A href="http://www.999jiujiu.com/">http://www.999jiujiu.com/</A></div>
<div class="container">
<div class="content"><br>CSS实现箭头的边框,我觉得还行吧^_^</div>
<s>
<i></i>
</s>
</div>
<br />
</body>
</html>
相关文章推荐
- java poi生成excel并修改excel样式
- 背景、边框样式及变形处理
- css中min-width与max-width
- Firefox与IE的CSS兼容CSS HACK技巧
- 父元素与子元素之间的margin-top问题(css hack)
- css 兼容性总结
- css伪类
- 11-5设定图层样式
- html和CSS学习笔记(2):标签和html文件基本结构
- Html和CSS学习笔记(1):Html和CSS的关系
- ZH奶酪:通过CSS自定义HTML中hr样式-颜色-形状
- ZH奶酪:纯CSS自定义Html中Checkbox复选框样式
- css3动画——常用的贝塞尔曲线
- css清除浮动float的三种方法总结,为什么清浮动?浮动会有那些影响?
- (一)初识div+css
- css实现布局
- CSS 定位和布局
- 浏览器 CSS Hack 收集
- 前些日子用css画的大白
- 第008讲 div css开山篇