• 请不要在回答技术问题时复制粘贴 AI 生成的内容
zjsxwc
V2EX  ›  程序员

html 里怎么让浏览器缩略图只出现 logo 而不是截屏

  •  
  •   zjsxwc ·
    zjsxwc · Mar 4, 2020 · 2132 views
    This topic created in 2451 days ago, the information mentioned may be changed or developed.

    浏览器里怎么让缩略图只出现 logo 而不是截屏,

    如图:

    whylogo

    这里知乎、github、淘宝、v 站都是 logo,但京东、有道字典、百度地图是截屏

    是 html 哪个 meta 数据的作用吗?

    leisure
    leisure
    Mar 4, 2020
    1
    favicon
    zjsxwc
    zjsxwc
    OP
    Mar 4, 2020
    2
    @leisure
    不是 favicon,是 icon,比如 v 站没有 favicon 只有 icon

    <link rel="icon" sizes="192x192" href="/static/img/v2ex_192.png" />
    <link rel="shortcut icon" href="/static/img/icon_rayps_64.png" type="image/png" />
    Torpedo
    Torpedo
    Mar 4, 2020
    3
    你看这个插件取的什么
    liKeYunKeji
    liKeYunKeji
    Mar 4, 2020
    4
    写了个 API,可以获取网站的 favicon
    ----------------------------------------------
    http://www.likeyunba.com/api/get_favicon.php?url=http://www.baidu.com
    otakustay
    otakustay
    Mar 4, 2020
    5
    @zjsxwc 那啥,link rel="icon"学名就叫 favicon……不存在 link rel="favicon"这种东西
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   2332 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 12:48 · PVG 20:48 · LAX 04:48 · JFK 07:48
    ♥ Do have faith in what you're doing.