Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hexo博客的gitment评论开启一直失败 #178

Open
JJXiangJiaoJun opened this issue Jan 18, 2019 · 14 comments

Comments

@JJXiangJiaoJun
Copy link

commented Jan 18, 2019

按照教程上配的,我的github pages绑定了个人域名
https//:hongbb.top
OAuth配置如下,应该是没有错误的

_config.yml的配置如下,保证client_id 和 client_secret没有填错

comment:
  gitment:
    enable: true
    owner: 'JJXiangJiaoJun' # 必填项, 你的GitHub ID
    repo: 'JJXiangJiaoJun.github.io' # 必填项  你的存储评论的repo
    oauth:
      client_id: 'd7df3d5d159f81371d76' # 必填项
      client_secret: '3794527fca067871d3795782ae7fd14f94ce3a74' # 必填项
      redirect_uri: # 可以填也可以不填

设置后博客上显示 Error: Comments Not Initialized

点击 登录 按钮后,无法跳转到github授权界面
浏览器上信息为 https://hongbb.top/?error=redirect_uri_mismatch&error_description=The+redirect_uri+MUST+match+the+registered+callback+URL+for+this+application.&error_uri=https%3A%2F%2Fdeveloper.github.com%2Fapps%2Fmanaging-oauth-apps%2Ftroubleshooting-authorization-request-errors%2F%23redirect-uri-mismatch

看起来好像是call-back url填错了,不过我试了 原来的URL也没用

@zithan

This comment has been minimized.

Copy link

commented Jan 22, 2019

作者自己的官方blog一样的问题:Error: Comments Not Initialized

@puddlejumper26

This comment has been minimized.

Copy link

commented Jan 24, 2019

我的也是,我是在 hexo d 之后,刷新页面,页面显示Error: Comments Not Initialized,点击Login,然后会跳出对话框[object ProgressEvent],点击确定之后,Gitment区域就显示Logging in... ,会一直持续下去,并且Gitment区域不能操作

@adangran

This comment has been minimized.

Copy link

commented Feb 7, 2019

同样的问题

@BlockBB

This comment has been minimized.

Copy link

commented Feb 13, 2019

我的也是,昨天弄的,github登陆之后浏览器显示:

[object XMLHttpRequestProgressEvent],然后一直在转圈。。。loading commetns

@sherry0429

This comment has been minimized.

@RikkaBlue

This comment has been minimized.

Copy link

commented May 4, 2019

可以看这里 https://sherry0429.github.io/2019/02/12/gitment%E4%BF%AE%E5%A4%8D/

你目前博客的gitment就会报object ProgressEven 不知道什么原因,我的icarus也是这种情况

@fireairforce

This comment has been minimized.

Copy link

commented May 21, 2019

我也遇到同样问题了 = =

@kopa-kongpan

This comment has been minimized.

Copy link

commented May 28, 2019

解决了吗 我也是一样的问题哎 满脑子很糊涂

@Chiang97912

This comment has been minimized.

Copy link

commented Aug 1, 2019

目前网上大部分解决方案都失效了,可以使用下面的方法解决:
打开你的blog本地仓库themes\next\layout_third-party\comments\gitment.ejs将

<link rel="stylesheet" href="https://imsun.github.io/gitment/style/default.css">
<script src="https://imsun.github.io/gitment/dist/gitment.browser.js"></script>

修改为:

<link rel="stylesheet" href="https://billts.site/extra_css/gitment.css">
<script src="https://billts.site/js/gitment.js"></script>

上面给出的是gitment汉化版

@JJXiangJiaoJun

This comment has been minimized.

Copy link
Author

commented Aug 1, 2019

说一下本人的 解决办法 :
我的github pages绑定了个人域名
https//:hongbb.top 导致重定向一直错误,我只修改了_config.yml 中的 redirect_uri , 就解决了问题,现在使用正常

comment:
  gitment:
    enable: true
    owner: 'JJXiangJiaoJun' # 必填项, 你的GitHub ID
    repo: 'JJXiangJiaoJun.github.io' # 必填项  你的存储评论的repo
    oauth:
      client_id: 'd7df3d5d159f81371d76' # 必填项
      client_secret: '3794527fca067871d3795782ae7fd14f94ce3a74' # 必填项
      redirect_uri: https//:hongbb.top    #如果绑定了个人域名,这里一定要填上绑定的个人域名!!!!!!!!!!!!!

可以试试将redirect_uri 改成自己绑定的个人域名

@chuhuilove

This comment has been minimized.

Copy link

commented Aug 4, 2019

按照楼上所说的方法,gitment没搞定.换了一个评论系统,gittalk ,https://yunhao.space/2018/07/04/hexo-next-gitalk-comments-tutor/这是教程地址..配置起来很简单..

@longxiaojiangi

This comment has been minimized.

Copy link

commented Aug 31, 2019

关于不能初始化的问题,我在手机上解决了。这是什么情况?

@f20500909

This comment has been minimized.

Copy link

commented Oct 9, 2019

说一下本人的 解决办法 :
我的github pages绑定了个人域名
https//:hongbb.top 导致重定向一直错误,我只修改了_config.yml 中的 redirect_uri , 就解决了问题,现在使用正常

comment:
  gitment:
    enable: true
    owner: 'JJXiangJiaoJun' # 必填项, 你的GitHub ID
    repo: 'JJXiangJiaoJun.github.io' # 必填项  你的存储评论的repo
    oauth:
      client_id: 'd7df3d5d159f81371d76' # 必填项
      client_secret: '3794527fca067871d3795782ae7fd14f94ce3a74' # 必填项
      redirect_uri: https//:hongbb.top    #如果绑定了个人域名,这里一定要填上绑定的个人域名!!!!!!!!!!!!!

可以试试将redirect_uri 改成自己绑定的个人域名

亲测无效

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
You can’t perform that action at this time.