我的网站图标不会显示在 index.php 上,但会显示在 google chrome 中的所有其他页面上。在火狐中工作

My favicon won't show on index.php but shows on all other pages in google chrome. Works in firefox

我的所有 php 页面都位于我的托管生产 linux 服务器上的一个文件夹 (public_html) 中。在该文件夹中,我有一个图像文件夹,其中包含我的图标。 index.php 以外的所有页面都显示图标。他们脑子里都有这个标签:

<link rel="icon" type="image/png" href="./images/t2.png">

知道为什么它不会在 google Chrome 中的 index.php 上显示吗?

编辑:"possible duplicate" 中的解决方案没有解决我的问题。

Chrome 有一个漂亮的 "sticky" 图标缓存,它有助于删除 Chrome 设置中保存的 files/images 并重新加载页面吗?您可以先尝试使用 ctrl+F5 (Win) 或 cmd+shift+R (Mac)。更多信息:https://www.nullalo.com/en/how-to-delete-google-chrome-favicon-cache/

通过将我的图标图像重命名为 favicon.ico 并将其放在根目录中解决了这个问题。没有更改 html 标题中的图标引用。 index.php 上的 Chrome 必须忽略该引用,但出于某种原因在其他页面上跟在后面。