简体   繁体   English

Safari 收藏夹/书签图标未显示

[英]Safari Favorites/Bookmark Icon not displaying

This pertains to Safari Bookmark and Favorites Icons这与 Safari 书签和收藏夹图标有关
No matter what I do, I cannot get my bookmark icon/favorites icon to appear.无论我做什么,我都无法显示我的书签图标/收藏夹图标。 I've tried the following:我尝试了以下方法:

 <link rel="icon" href="/images/favicon.png" type="image/x-icon">

Waited for days, cleared my cache, and nothing.等了几天,清除了我的缓存,什么也没有。 Then I added:然后我补充说:

 <link rel="icon" type="image/png" href="https://mywebsite.com/images/favicon-96x96.png" sizes="96x96">
 <link rel="icon" type="image/png" href="https://mywebsite.com/images/favicon-144x144.png" sizes="144x144">

And it still doesn't work.它仍然不起作用。 I also added an apple-touch-icon.png in my root directory, and this works, but only for adding my website to the homescreen.我还在我的根目录中添加了一个 apple-touch-icon.png ,这有效,但仅用于将我的网站添加到主屏幕。 For bookmarks and favorites, it still shows just the first letter of my website.对于书签和收藏夹,它仍然只显示我网站的第一个字母。

I've researched everywhere and nothing seems to work, have things changed?我到处研究,似乎没有任何效果,情况有变化吗? Help is much appreciated, thank you!非常感谢您的帮助,谢谢!

The most commonly accepted way is to have a favicon.ico file in your site's root directory.最普遍接受的方法是在您站点的根目录中有一个favicon.ico文件。 You can generate a favicon file here .您可以在此处生成网站图标文件。

To set icons explicitly you can look here , but this is complementary.要明确设置图标,您可以查看此处,但这是补充性的。

对于 iOS 11.4,您必须先关闭 Safari 应用程序,然后再清除缓存数据。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM