Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How switch off image border in IE

I'm trying to remove the image border in ie, but I get some strange behavior.

Here's my code:

img {border: none}
<img src="..." border="0" style="border: 0"/>

But it's still not working, and IE debugger shows me image border: medium. And my div is larger by 10px per image.

like image 999
Kein Avatar asked Jun 02 '10 14:06

Kein


People also ask

How do I get rid of the border on Internet Explorer?

add style="border: none;" to whatever creates the border or create a css with this attribute.

How do I hide a picture border?

Adding border="0" to your img tag prevents that picture from having a border around the image. However, adding border="0" to every image would not only be time consuming but also increase the file size and download time. To prevent all images from having a border, create a CSS rule or file with the following code.

How do I disable border?

Go to Design > Page Borders. In the Borders and Shading box, on the Page Border tab, select the arrow next to Apply to and choose the page (or pages) you want to remove the border from. Under Setting, select None, and then select OK.


2 Answers

Try

img {
  border-width: 0;
}
like image 150
Robusto Avatar answered Oct 08 '22 19:10

Robusto


Remove border from image link:

a img
{
     border:0px;
}

Works fine on IE

like image 43
Faisal Avatar answered Oct 08 '22 17:10

Faisal