首页 > Web开发 > 详细

CSS3实现选项卡

时间:2019-01-12 12:42:18      阅读:163      评论:0      收藏:0      [点我收藏+]
<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title></title>
        <style type="text/css">
            *{
                margin: 0;
                padding: 0;
            }
            a{
                text-decoration: none;
                color: deeppink;
            }
            div{
                width: 200px;
                height: 200px;
                background: pink;
                display: none;
                text-align: center;
                font: 50px/200px "微软雅黑";
            }
            :target{
                display: block;
            }
        </style>
    </head>
    <body>
        <a href="#div1">div1</a>
        <a href="#div2">div2</a>
        <a href="#div3">div3</a>
        <div id="div1">
            div1
        </div>
        <div id="div2">
            div2
        </div>
        <div id="div3">
            div3
        </div>
    </body>
</html>

CSS3实现选项卡

原文:https://www.cnblogs.com/panlaixing/p/10259221.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!