个性化hexo博客,添加评论系统,分享,友情链接功能
个人博客地址:http://lx.nextdev.cn
前言
上一篇文章我们用 coding page + hexo 搭建了个人博客,这篇文章我们将对博客进行修改
注意,本篇文章一切修改基于hexo
博客的next
主题
评论系统
网易云跟贴
开始使用
注册一个账号,然后打开获取代码
的WEB代码
,找到productKey
打开主题配置文件,找到
Gentie productKey
,修改为以下代码:
# Gentie productKey
gentie_productKey: 在这里写key
OK!
分享系统
ShareSDK
开始使用
注册一个账号,然后打开后台,找到appkey
打开
博客\themes\next\layout\_partials\share
新建一个文件名为
sharesdk.swig
,并输入以下代码:
<!--MOB SHARE BEGIN--><div class="-mob-share-ui-button -mob-share-open">分享</div><div class="-mob-share-ui" style="display: none"><ul class="-mob-share-list"><li class="-mob-share-weibo"><p>新浪微博</p></li><li class="-mob-share-tencentweibo"><p>腾讯微博</p></li><li class="-mob-share-qzone"><p>QQ空间</p></li><li class="-mob-share-qq"><p>QQ好友</p></li><li class="-mob-share-weixin"><p>微信</p></li><li class="-mob-share-douban"><p>豆瓣</p></li><li class="-mob-share-renren"><p>人人网</p></li><li class="-mob-share-kaixin"><p>开心网</p></li><li class="-mob-share-facebook"><p>Facebook</p></li><li class="-mob-share-twitter"><p>Twitter</p></li><li class="-mob-share-pocket"><p>Pocket</p></li><li class="-mob-share-google"><p>Google+</p></li><li class="-mob-share-youdao"><p>有道云笔记</p></li><li class="-mob-share-mingdao"><p>明道</p></li><li class="-mob-share-pengyou"><p>朋友网</p></li><li class="-mob-share-tumblr"><p>Tumblr</p></li><li class="-mob-share-instapaper"><p>Instapaper</p></li><li class="-mob-share-linkedin"><p>LinkedIn</p></li></ul><div class="-mob-share-close">取消</div></div><div class="-mob-share-ui-bg"></div><script id="-mob-share" src="http://f1.webshare.mob.com/code/mob-share.js?appkey={{ theme.shareSDKappkey }}"></script><!--MOB SHARE END-->
打开:
LX-Blog\themes\next\layout\post.swig
将以下代码:
<div class="post-spread">{% if theme.jiathis %}{% include '_partials/share/jiathis.swig' %}{% elseif theme.baidushare %}{% include '_partials/share/baidushare.swig' %}{% elseif theme.add_this_id %}{% include '_partials/share/add-this.swig' %}{% elseif theme.duoshuo_shortname and theme.duoshuo_share %}{% include '_partials/share/duoshuo_share.swig' %}{% endif %}</div>
改成:
<div class="post-spread">{% if theme.jiathis %}{% include '_partials/share/jiathis.swig' %}{% elseif theme.baidushare %}{% include '_partials/share/baidushare.swig' %}{% elseif theme.add_this_id %}{% include '_partials/share/add-this.swig' %}{% elseif theme.duoshuo_shortname and theme.duoshuo_share %}{% include '_partials/share/duoshuo_share.swig' %}{% elseif theme.sharesdk %}{% include '_partials/share/sharesdk.swig' %}{% endif %}</div>
打开
主题配置文件
,添加以下代码:
sharesdk: true
shareSDKappkey: 你的appkey
添加友情链接
打开
主题配置文件
,找到Blog rolls
,将代码改成:
links_title: 友情链接
links_layout: inline
links: 凌霄的博客: http://lx.nextdev.cn/
完成!
欢迎评论
个性化hexo博客,添加评论系统,分享,友情链接功能相关推荐
- Hexo博客添加评论功能
Hexo博客添加评论功能 实现了Hexo的评论功能 先附上官网链接valine官网 我使用的是Material-X主题,大多主题都支持,基本在官方主题文档都可以找到使用方法 1.进入官网,注册账号 需 ...
- 基于.NetCore开发博客项目 StarBlog - (13) 加入友情链接功能
系列文章 基于.NetCore开发博客项目 StarBlog - (1) 为什么需要自己写一个博客? 基于.NetCore开发博客项目 StarBlog - (2) 环境准备和创建项目 基于.NetC ...
- Hugo项目实战-集成评论博客添加评论功能
实践效果 Quick Start Install Hugo brew install hugo # or port install hugohugo version Create a New Site ...
- hexo博客添加暗色模式_我如何向网站添加暗模式
hexo博客添加暗色模式 同一个网站,两种不同的配色方案 (Same website, two different color schemes) Last year I made it a point ...
- hexo博客添加本地搜索功能
写在前面 本文主要描述了怎么添加hexo博客搜索插件,然后启动搜索功能,对两个本地搜索插件的使用进行了描述,文章可能还有很多不足,请大家谅解,欢迎大佬提意见. 本文用的东西 hexo 3.1.0 wi ...
- 为 hexo 博客添加本地搜索功能
点击上方 好好学java ,选择 星标 公众号 重磅资讯.干货,第一时间送达 今日推荐:我的大学到研究生自学 Java 之路,过程艰辛,不放弃,保持热情,最终发现我是这样拿到大厂 offer 的!个人 ...
- hexo博客添加暗色模式_我如何将暗模式添加到我的网站
hexo博客添加暗色模式 I recently redesigned my website. Here are 2 pictures of how it looked, for reference: ...
- Hexo 博客添加看板娘
Hexo 博客添加看板娘 相信看到这里的小伙伴都有属于自己的hexo博客了吧,废话不多说,我们直接进入主题 我的博客:传送门 1.安装模块 在hexo根目录下用Git执行命令 npm install ...
- hexo yilia主题添加评论系统详细教程
文章目录 序言 添加相关代码 1. config.yml 2. yilia\layout\_partial\article.ejs 3.valine.ejs 安装评论 序言 其实网上关于Hexo的博客 ...
- 向Hexo博客添加微博秀(pug模板)
目的 本文是一个详细的教程,告诉大家如何在Hexo博客中嵌入微博秀或者微博直播组件. 为什么要向博客中添加微博秀/微博直播组件? 微博秀是什么 新浪微博秀,可以放置在你的博客.网站,或是其它支持htm ...
最新文章
- python socket编程
- 关于tomcat无法启动问题详解
- 【机器学习】机器学习中缺失值处理方法大全(附代码)
- 泛型的作用是什么?——Java系列学习笔记
- word文档图标变成白纸_挽救你的文件 修复变成乱码的Word文档
- dcmm认证的条件_DCMM认证 数据管理能力成熟度模型评估
- 数据库的基本操作、增删查改
- CTS(11)---android自动化测试CTS源码分析之一
- jquery 动画总结(主要指效果函数)
- [NAACL19]一个更好更快更强的序列标注成分句法分析器
- mhdd测试hdd硬盘软件,HDD坏道检测软件比较(DiskGenius/HdTunePro/MHDD等)
- UC浏览器去广告、联网、升级(支持新版8.1)
- python函数注释:函数后面的箭头->
- 判断一个数是否为素数 java_java中如何判断一个数是否是素数(质数)
- 尺规作图切线的画法_基于尺规作图的新型公切线画法
- java 背单词系统_背单词系统
- GitLab使用中的403错误
- python输出集合中的所有子集_python列出集合中所有子集
- 东小店南少:让你终身收益的三个营销思维,看完不再迷茫!
- 华为设备常见AAA操作