Html+CSS 画出三角形(HTML+CSS百例练习)

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style type="text/css">
        .box{
            width: 0px;
            height: 0px;
            background-color: white;
            /* border-bottom: 50px solid transparent;
            border-left: 50px solid transparent;
            border-right: 50px solid transparent; */
            border: 50px solid transparent;
            border-top: 50px solid blue;
        }
    </style>
</head>
<body>
    <div class="box"></div>
</body>
</html>

!回车

div.box 回车

style 回车。。。。

猜你喜欢

转载自blog.csdn.net/PieroPc/article/details/131350154