我试图设置span标签的背景图像,使其填充span的背景。span的大小是可变的。span的背景不应重复。
<span class="link-shape" ></span>
CSS:
.img-rectangular .link-shape {
background-image: url(images/icon-link.png);
position: absolute;
top: 35%;
left: 35%;
height: 20%;
width: 20%;
z-index:-1;
}
.img-rectangular:hover .link-shape {
z-index:100000;
}
.