开发者

Border not given but shown around an image against a colored background

I am not going to paste the code as I hope that is not so important here.

an image is placed against a colored background (background made colored by background-color property ). surprisingly blue border is shown around the image.

What 开发者_运维技巧is the secret? how can i remove the border?

tnx beforehand.

Istiaque Ahmed Bangladesh


Is the image inside a link (<a>)? That tends to put a blue border around the image. You can remove it by setting a border: 0 on the image (or some class the image is in).


Let me guess, the image is inside an a tag?

A border shows up for an image that is a link unless you explicitly remove the border.

You can remove the border with css:

img {
  border: none;
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜