disqus评论正在此处加载:http://www.oddprints.com/help 但不是这里:https://www.oddprints.com/help任何想法?
所有资源似乎都是安全的(协议相对网址),所以我不认为这是。
答案 0 :(得分:4)
因为disqus将两个URL视为不同,因此加载不同的线程。如果您希望http和https网址都包含相同的评论主题,则需要在disqus配置中提供规范网址。我就这样做了:
<div id="disqus_thread"></div>
<script>
/**
* https://disqus.com/admin/universalcode/#configuration-variables
*/
var disqus_config = function () {
this.page.url = "http://www.oddprints.com/help";
//this.page.identifier = "oddprints"; // add a different id here if you want a fresh thread....
};
(function() {
var d = document, s = d.createElement('script');
s.src = '//oddprints.disqus.com/embed.js';
s.setAttribute('data-timestamp', +new Date());
(d.head || d.body).appendChild(s);
})();
</script>
<noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript" rel="nofollow">comments powered by Disqus.</a></noscript>
请注意,在配置中,我将http
网址作为规范网址传递,我没有设置page.identifier
。我已经完成了这项工作,以便它继续提供我刚从http
使用较旧版本的disqus片段时的评论。
答案 1 :(得分:1)
Disqus评论已加载但是Disqus将这两个页面视为不同。
您是否遵循了这一点:https://help.disqus.com/customer/portal/articles/542119-can-disqus-be-loaded-via-https-?