点击图片实现跳转,背景图片也随之跳转,类似于拉手风琴
代码实现
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>手风琴效果</title>
<style type="text/css">
*{
margin: 0;
padding: 0;
list-style: none;
}
body{
height: 100vh;
background-image: url(./img/李现.jpg);
background-size: cover;
background-position: center