简体   繁体   English

Disqus评论总数0评论

[英]Disqus Comment Count Always 0 Comments

I think I've set up Disqus as instructed for universal code. 我想我已按照通用代码的指示设置了Disqus。

Trouble is that it always says that a post has 0 comments. 麻烦的是它总是说帖子有0条评论。

Take this post: http://tx0rx0.com/retropie-and-the-raspberry-pi/ 请看这篇文章: http//tx0rx0.com/retropie-and-the-raspberry-pi/

which discus says has 11 comments, and then compare to the front page 铁饼说有11条评论,然后与头版进行比较

http://tx0rx0.com http://tx0rx0.com

I thought all you needed was a link to the page with the disqus comments with #disqus_thread appended to it. 我认为你所需要的只是一个链接到页面,其中包含带有#disqus_thread的disqus注释。 Like so: 像这样:

<a href="tx0rx0.com/retropie-and-the-raspberry-pi#disqus_thread>Comments</a>

and the javascript with correct shortname would do the rest. 并且具有正确短名称的javascript将完成其余的工作。 Where did I go wrong? 我哪里做错了? Also, why is there a period there? 另外,为什么会有一段时间呢?

The protocol and presence of trailing slashes matter when it comes to comment count lookups. 在注释计数查找时,协议和尾随斜杠的存在很重要。 Try this: 尝试这个:

<a href="http://tx0rx0.com/retropie-and-the-raspberry-pi/#disqus_thread">Comments</a>

You might also consider using a 'disqus_identifier' and 'disqus_url' with the commenting embed, which you can then use in the comment count link like this: 您还可以考虑将'disqus_identifier'和'disqus_url'与注释嵌入一起使用,然后您可以在注释计数链接中使用,如下所示:

<a href="http://tx0rx0.com/retropie-and-the-raspberry-pi/#disqus_thread" data-disqus-identifier="some_identifier_for_thread">Comments</a>

This will normalize the data between what is passed to us, and what you're expecting when you render the comment count links. 这将规范化传递给我们的内容与您在呈现评论计数链接时所期望的数据之间的数据。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM