background-image,background-repeat, background-position 实现点赞图片(一个图片的多次使用)

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
    <div style="height:100px">
    
    </div>
    <div style="background-image: url(微博/icon_18_118.png); background-repeat: no-repeat; border: 1px solid red; height: 20px; width:20px;background-position: 1px -39px;">
        
    </div>
    

</body>
</html>

猜你喜欢

转载自www.cnblogs.com/my-love-is-python/p/9291371.html