Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IMG Tag Remove Border

Tags:

html

http://www.flirtwithme.co/main.php#upgrade

On this page there is a blue box image that has a grey border around it. I've been trying to remove the border without luck:

eg:

border: none;
outline: none;

the image is part of a sprite and there is no border around the image. Any ideas?

* the image is the one on the right - blue box with a tick in it. (second one on the top in the sprite.

like image 348
Adam Avatar asked Oct 11 '11 09:10

Adam


People also ask

How do I remove the border from an image tag?

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 turn off borders in HTML?

Note: you can use “border: none;” or “border: 0px;”. Either way it results in the outside border being removed from your table.

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.


1 Answers

your image has no src attribute add a transparent.gif to the source and the border will disappear.

Example:

<img class="benefitImg" id="iconPersonalizeProfile" src="http://upload.wikimedia.org/wikipedia/commons/c/ce/Transparent.gif">

UPDATE:

Example for sprited background images on list elements. (In this case you have to rearrange the sprite into a vertical sprite)

http://jsbin.com/ebovod/edit#html,live

like image 87
Burntime Avatar answered Sep 20 '22 22:09

Burntime