通过查询资料,网络上有两种写法:语句一:语句二:type可以设置_shortcut icon">
当前位置:   article > 正文

使用link rel=“shortcut icon“为网页标题加图标

shortcut icon
<title>会员卡券</title>
<link rel="shortcut icon" href="http://GT/img/favicon.png" type="image/x-icon">
  • 1
  • 2

在这里插入图片描述
通过查询资料,网络上有两种写法:

语句一:<link rel="shortcut icon" href="图片地址" />
语句二:<link rel="icon" href="图片地址" type="image/gif" />
  • 1
  • 2

type可以设置多种图片类型。如:gif/png/ico
一般的图标尺寸都是16px*16px

静态的图标文件使用:

<link rel="shortcut icon" href="1.png" type="image/x-icon" />
  • 1

动态图 gif(动画也是16*16)使用:

<link rel="icon" href="1.gif" type="image/gif" >
  • 1

关于shortcut icon和icon代码的区别介绍
有一个博客有写 http://blog.csdn.net/ssisse/article/details/51705626 链接放在这里 方便以后看

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/知新_RL/article/detail/339049
推荐阅读
相关标签
  

闽ICP备14008679号