Disqus“显示评论”按钮停止工作

问题描述 投票:0回答:0

我有一个使用 Disqus 进行评论的网站。我用一个按钮来隐藏评论。用户必须点击“2 条评论”按钮才能看到评论:

对于评论为零的博客文章,Disqus 加载。

如果我尝试单击带有评论的网站上的按钮,什么也不会发生。

例如-尝试点击“2条评论”按钮。 https://john.soban.ski/m30-linux.html#disqus_thread

我使用以下代码:

 <script type="text/javascript">
                    var disqus = 'freshlex';
                    var disqus_shortname = 'freshlex';
                    var disqus_identifier = '/m30-linux.html';
                    var disqus_url = 'https://john.soban.ski/m30-linux.html';
                </script>
                <noscript>Please enable JavaScript to view the comments.</noscript>
                <section class="post-comments">
                        <a id="show-disqus" class="post-comments-activate" data-disqus-identifier="/m30-linux.html" >Show Comments</a>
                    <div id="disqus_thread"></div>
                </section>

<script type="text/javascript">
    var disqus_shortname = 'freshlex';
    (function () {
        var s = document.createElement('script'); s.async = true;
        s.type = 'text/javascript';
        s.src = '//' + disqus_shortname + '.disqus.com/count.js';
        (document.getElementsByTagName('HEAD')[0] || document.getElementsByTagName('BODY')[0]).appendChild(s);
    }());
</script>
javascript disqus pelican
© www.soinside.com 2019 - 2024. All rights reserved.