10

我在这个网站上工作:http: //amberdreams.com

这是一个非常简单的站点,我一直在使用 netrenderer.com 来确保所有页面都可以在 Internet Explorer 中运行。

尽管我尽了最大的努力,但在使用 Internet Explorer 9 查看此站点时,我仍无法删除该站点主页上 facebook 和 twitter 链接周围的蓝色边框。

img {border: none; }
a img {border: 0px; }

我已经尝试了上面代码的变体,它成功地删除了除 9 之外的每个版本的 IE 的蓝色边框。有什么想法吗?

4

8 回答 8

26

在你的 CSS 中试试这个,对我有用。

img {text-decoration: none; border: 0px}
于 2012-11-12T11:40:24.213 回答
3

我觉得应该没问题。

您可能想清除缓存并重试...

如果不是,请尝试:

a{border:none}
于 2012-04-23T17:10:18.647 回答
3

在您的 css 中尝试以下操作:

border-style:none;

那应该消除您的边界问题。

于 2012-04-23T17:10:39.727 回答
1

这是关于删除大纲的精彩帖子,并单独评论了 IE9:

George Langley 写道,IE 9 显然不允许您删除链接周围的虚线轮廓,除非您包含此元标记:

<meta http-equiv="X-UA-Compatible" content="IE=9" />
于 2013-11-13T15:57:15.923 回答
1

链接周围边框的可见性取决于 IE 中的用户设置。设置A {text-decoration: none; border: 0px}

看来,您的视频对象未在 IE 中加载。

于 2012-04-23T17:18:18.000 回答
1

//添加到你的CSS

* {-ms-box-sizing:border-box;}
img {outline-style: none;}

//添加到你的 HTML

<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
</head>
于 2017-04-20T03:52:55.320 回答
0

在我的情况下,工作代码(由 mailchimp 生成并为“a”添加规则)是:

img,a img,a{
    border:0;
    height:auto;
    outline:none;
    text-decoration:none;
}

所以这是对其他答案的假设

于 2017-01-26T17:43:39.930 回答
-2

最好的方法是添加一个 CSS 属性

a:link, a:visited { text-decoration: none}

如果要在鼠标悬停时更改颜色,请添加

a:hover {color: x } // x = the color of your choice
于 2017-09-06T20:26:46.273 回答