Why does my favicon not show up?

后端 未结 4 1393
情歌与酒
情歌与酒 2020-12-16 09:11

The following is used to set the favicon in my html code:


However, the

4条回答
  •  心在旅途
    2020-12-16 09:32

    1. Is it really a .ico, or is it just named ".ico"?
    2. What browser are you testing in?

    The absolutely easiest way to have a favicon is to place an icon called "favicon.ico" in the root folder. That just works everywhere, no code needed at all.

    If you must have it in a subdirectory, use:

    
    

    Note the / before img to ensure it is anchored to the root folder.

提交回复
热议问题