Favicon is getting displayed on the admin dashboard but not on any browser

前提是你 提交于 2019-12-12 01:45:57

问题


I have added a favicon.ico file in my root directory and have also added the image as site identity. Favicon is getting displayed in my admin pages but not on any browser. Here is the link for the website "www.acrosszero.org"


回答1:


Add an .ico image file (16x16 or 32x32 pixels) to the folder where is the page you want to display it. Then, in that page, edit the source code: inside the <head> tag (if it doesn't exist, you create), wich is inside the <body> tag, add:

<link rel='shortcut icon' href='favicon.ico' type='image/x-icon'/ >

Then close the tag this way:

</head>

Save the page and reload.




回答2:


This occurs sometimes when the favicon is too large.

To create a favicon that fits use the following dimensions:

  • widht: 512px
  • height: 512px


来源:https://stackoverflow.com/questions/35670507/favicon-is-getting-displayed-on-the-admin-dashboard-but-not-on-any-browser

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!