图标在 IE 中不起作用 [英] favicon not working in IE

查看:41
本文介绍了图标在 IE 中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个使用自定义 favicon.ico 的网站.网站图标在除 IE 之外的所有浏览器中均按预期显示.尝试在 IE 中显示网站图标时,出现红色的大 x;在另一个浏览器中显示图标时,它显示得很好.页面来源包括它确实适用于其他浏览器.谢谢你的想法.

已解决:问题的根源是该文件是重命名为 ico 的 jpg.我将文件创建为 ico,它按预期工作.感谢您的投入.

解决方案

是的,您并没有那么有帮助(提供源代码会非常有用!)>

代码是这样的:

<link rel="快捷图标" href="http://www.example.com/favicon.ico" type="image/x-icon"/>

是在中吗?

图像是真实的 ico 文件吗?(重命名位图不是真正的 .ico!格式略有不同)

将页面添加为书签是否有效?

I have a site using a custom favicon.ico. The favicon displays as expected in all browsers except IE. When trying to display the favicon in IE, I get the big red x; when displaying the favicon in another browser, it displays just fine. The page source includes and it does work in other browsers. Thanks for your thoughts.

EDIT: SOLVED: The source of the issue was the file was a jpg renamed to ico. I created the file as an ico and it is working as expected. Thanks for your input.

解决方案

Right you've not been that helpful (providing source would be have been really useful!) but here you go... Some things to check:

Is the code like this:

<link rel="icon" href="http://www.example.com/favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="http://www.example.com/favicon.ico" type="image/x-icon" />

Is it in the <head>?

Is the image a real ico file? (renaming a bitmap is not a real .ico! Mildly different format)

Does it work when you add the page as a bookmark?

这篇关于图标在 IE 中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆