Solution to the problem that the background image of a tag is not displayed under IE8_HTML/Xhtml_Web page production

WBOY
Release: 2016-05-16 16:36:34
Original
1260 people have browsed it

I encountered a small problem today and struggled with it for a long time. I want to share the

a tag to add a background image. I need to add the display:block style

to a. However, the background image still cannot be displayed under IE8. Let’s start. I thought it was because the a tag was empty. I tried adding content but it didn’t work. Then I noticed a little detail and it can be displayed normally after modification.

Before modification:

Copy code
The code is as follows:

background: url('./img/active/legendBg.png')no- repeat


After modification:

Copy code
The code is as follows:

background: url('./img/active/legendBg.png') no-repeat

Did you notice, it’s because of that space. .
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template