個人博客:凌霄的博客
打開seo
- 在
主題配置文件中找到:
seo: false
將其設(shè)置為true
百度鏈接提交
- 自動提交:
- 打開主題配置文件,找到
baidu_push,將其設(shè)置為true
baidu_push: true
- 鏈接提交
sitemap
- 首先安裝兩個插件:
npm install hexo-generator-sitemap --save
npm install hexo-generator-baidu-sitemap --save
- 然后打開百度站長平臺

Paste_Image.png
- 添加
http://lx.nextdev.top/baidusitemap.xml
http://lx.nextdev.top/sitemap.xml
-
添加
robots.txt
# hexo robots.txt
User-agent: * Allow: /
Allow: /archives/
Disallow: /vendors/
Disallow: /js/
Disallow: /css/
Disallow: /fonts/
Disallow: /vendors/
Disallow: /fancybox/
Sitemap: 你的域名/sitemap.xml
Sitemap: 你的域名/baidusitemap.xml
- 放在
博客/source/目錄下
給出站鏈接加上no follow屬性:
打開博客\themes\next\layout\_partials\footer.swig 文件
給下列鏈接加上no follow屬性:
{{ __('footer.powered', '<a class="theme-link" ) }}
<a class="theme-link" >
打開博客\themes\next\layout_macro,將下面代碼中的a標(biāo)簽加no follow屬性:
<a href="{{ link }}" target="_blank">{{ name }}</a>
<a href="http://creativecommons.org/licenses/{{ theme.creative_commons }}/4.0" class="cc-opacity" target="_blank">
title的優(yōu)化
打開 your-hexo-site\themes\next\layout\index.swig,將下面代碼:
{% block title %} {{ config.title }} {% endblock %}
改為
{% block title %} {{ config.title }} - {{ theme.description }} {% endblock %}
完成!
歡迎評論
