简体   繁体   English

从网站为移动firefox提供主屏幕图标

[英]Provide home-screen icon for mobile firefox from web site

For the Chrome browser on Android 对于Android上的Chrome浏览器

<link rel="icon" sizes="180x180" href="apple-touch-icon.png">

as well as for Safari on Apple devices 以及Apple设备上的Safari

<link rel="apple-touch-icon" href="apple-touch-icon.png">

there are ways to tell the browser which icon to use when the user wants to place a bookmark/shortcut on the device's home screen. 当用户想要在设备的主屏幕上放置书签/快捷方式时,有办法告诉浏览器使用哪个图标。

Does anyone know positively that Firefox on Android supports something like this. 有没有人肯定知道Android上的Firefox支持这样的东西。 At least the current version I have does not care at all for any of the two link-elements above. 至少我当前的版本对上面的两个链接元素中的任何一个都不关心。

Firefox will use the image embedded in the favicon for all links save from the related website. Firefox将使用favicon中嵌入的图像从相关网站保存所有链接。

Currently there is no other way I am aware of to overide this functionality. 目前,我没有其他任何方法可以覆盖此功能。

<link rel="shortcut icon" href="favicon.ico"/>

Mozilla appear to be working a modernising the file icon in future releases. Mozilla似乎正在为将来的版本中的文件图标进行现代化改造。

https://bugzilla.mozilla.org/show_bug.cgi?id=926139 https://bugzilla.mozilla.org/show_bug.cgi?id=926139

This works for me, but in some rare cases FireFox offers no icon at all: 这适用于我,但在极少数情况下,FireFox根本不提供任何图标:

<link rel="apple-touch-icon-precomposed" href="/favicon-196.png" sizes="196x196">

In case FireFox offers no icon I relaunch the browser and try again. 如果FireFox没有提供图标,我会重新启动浏览器并重试。
This also works for Chrome and should work for Apple devices which I haven't tested. 这也适用于Chrome,适用于我尚未测试过的Apple设备。
I use 196x196 because it is suggested for Android's Chrome home screen icon. 我使用的是196x196,因为建议使用Android的Chrome主屏幕图标。

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

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