题解 | #定位 - relative#

定位 - relative

http://www.nowcoder.com/practice/c940df050f3645529df374e3e1c1994e

<html>
    <head>
        <meta charset=utf-8>
        <style type="text/css">
            * {
                margin: 0;
                padding: 0;
            }
            .left {
                width: 100px;
                height: 100px;
                background-color:blue;
            }
            .center {
                width: 100px;
                height: 100px;
                position: relative;
                left: 50px;
                top: 50px;
                background-color:pink;
            }
            .right {
                width: 100px;
                height: 100px;
            }
        </style>
    </head>
    <body>
    	<div class="left"></div>
        <div class="center"></div>
        <div class="right"></div>
    </body>
</html>
全部评论

相关推荐

点赞 评论 收藏
分享
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客企业服务