html-背景圖片
阿新 • • 發佈:2018-12-10
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> <style> *{ margin: 0px; padding: 0px; } .da{ border: 1px solid black; height: 400px; width: 800px; margin: 20px auto; background: url("image2/2.png"); background-repeat: no-repeat; background-size: 200px; background-position: right 40px; } </style> </head> <body> <div class="da"></div> </body> </html>
效果圖: