본문 바로가기

HTML&CSS

CSS박스에 배경꾸미기 //Decoration the background on the box

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<!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>
        div{background-color: skyblue;
        background-size: 100px 100px;
        background-image: url(media/Spongebob.png);
        background-repeat: repeat-y;
        background-position: center center;
        
        width: 200px;
        height: 200px;
        color: blueviolet;
        font-size: 16px;
        }
 
    </style>
</head>
<body>
    <h3>박스에 배경꾸미기</h3><hr>
    <div>SpongeBob is an over-optimistic
        sponge that annoys other characters. </div>
</body>
</html>
http://colorscripter.com/info#e" target="_blank" style="color:#4f4f4ftext-decoration:none">Colored by Color Scripter
http://colorscripter.com/info#e" target="_blank" style="text-decoration:none;color:white">cs