以下页面已加密,密码为:123456
你的网站文件夹,举例为website
。
命令行进入到webiste
目录。
执行命令安装hexo插件:
npm install hexo-blog-encrypt
_config.yml
文件(注意不是A4主题的配置文件)# hexo 支持 加密访问文章 插件
encrypt:
enable: true
abstract: Here's something encrypted, password is required to continue reading.
message: Hey, password is required here.
wrong_pass_message: Oh, this is an invalid password. Check and try again, please.
wrong_hash_message: Oh, these decrypted content cannot be verified, but you can still have a look.
front-matter
中添加password: 123456
hexo clean && hexo g && hexo s
引用: