简体   繁体   中英

ie6 and ie7 remove border around image sprites

Im using image sprites across my site.

in IE6 and IE7 a gray border appears around the images.. works fine in the other browsers +IE8

how can i remove it?
here it is the bottom one is a div:

在此处输入图片说明

我将图片标签更改为div,并且有效。

html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,
acronym,address,big,cite,code,del,dfn,em,font,img,ins,kbd,q,s,samp,small,strike,strong,
sub,sup,tt,var,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,
thead,tr,th,td
{
    border:0;
    font-weight:inherit;
    font-style:inherit;
    font-size:100%;
    font-family:inherit
}

Added that code to my main css file and all the borders in IE7 disappeared.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM