前言
在某些网页中,为了能让浏览器更好的搜索到该网页,就会使用logo SEO来提权!
代码部分
<div class="logo"><h1><a href="index.html" title="小米商城">小米商城</a></h1><!-- 这里设置li就是为了提权,然后h1里面再放一个链接图片由背景引入 --></div>
*{margin: 0;padding: 0;font-size: 12px;}.logo{width: 50px;height: 50px;background-image: url("../mi/img/mi-logo.png");background-size: 100% 100%;background-color: coral;}h1{width: 100%;height: 100%;}.logo a{display: block;width: 100%;height: 100%;text-indent: -9999px;overflow: hidden;/*这里只有设置了display后面的-9999px才会生效!!!方法二:直接给font-size:0*/}