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

带三角形的边框

时间:2017-05-08 17:25:38      阅读:121      评论:0      收藏:0      [点我收藏+]

标签:20px   play   边框   title   tran   splay   order   ash   对话   

大家可直接复制粘贴,利用css3的一些新属性,即可实现气泡的对话框

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title></title>
    <style type="text/css">
        .tag
        {
            width: 300px;
            height: 100px;
            border: 5px solid #09F;
            position: relative;
        }
        .tag em
        {
            display: block;
            border-width: 20px;
            position: absolute;
            bottom: -40px;
            left: 100px;
            border-style: solid dashed dashed;
            border-color: #09F transparent transparent;
            font-size: 0;
            line-height: 0;
        }
        .tag span
        {
            display: block;
            border-width: 20px;
            position: absolute;
            bottom: -33px;
            left: 100px;
            border-style: solid dashed dashed;
            border-color: #FFF transparent transparent;
            font-size: 0;
            line-height: 0;
        }
    </style>
</head>
<body>
    <div class="tag">
        <em></em>CSS气泡框实现
    </div>
    <div class="tag" style="margin-top: 100px">
        <em></em><span></span>CSS气泡框实现
    </div>
</body>
</html>

带三角形的边框

标签:20px   play   边框   title   tran   splay   order   ash   对话   

原文地址:http://www.cnblogs.com/zsq94/p/6825990.html

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