Blogger Information
Blog 12
fans 0
comment 0
visits 10524
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
利用position: absolute绝对定位实现用色块制作一个十字架
A骆长林的博客
Original
1187 people have browsed it

实例

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>绝对定位</title>
    <style type="text/css">
        .div11{
            position: relative;}
        .div1{width: 100px;height: 100px;background-color: #ffff0a;position: absolute;left: 100px;}
        .div2{width: 100px;height: 100px;background-color: royalblue;position: absolute;
            top: 100px;}
        .div3{width: 100px;height: 100px;background-color: rosybrown;position: absolute;top:100px;left: 200px;}
        .div4{width: 100px;height: 100px;background-color: burlywood;position:absolute;top:200px;left: 100px;}
    </style>
</head>
<body>
<div class="div11">
<div class="div1"></div>
<div class="div2"></div>
<div class="div3"></div>
<div class="div4"></div>
</div>
</body>
</html>

运行实例 »

点击 "运行实例" 按钮查看在线实例


Correction status:Uncorrected

Teacher's comments:
Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments