我需要在受密碼保護的帖子上隱藏Disqus評論,直到用戶輸入正確的密碼。我已經與Disqus就此進行了聯繫......首先他們告訴我啓用disqus_developer變量。所以我把它添加到Wordpress中的header.php中:在密碼保護的帖子中顯示Disqus,直到輸入密碼爲止?
<script type="text/javascript">
var disqus_developer = 1; // developer mode is on
</script>
但是這並沒有做任何事。然後,Disqus支持對我說:
你將不得不一些邏輯添加到您的代碼,除非輸入密碼不加載Disqus 。這是您需要在您的主題/模板中自定義的 。
他們沒有給出如何實現這一目標的方向。我需要做什麼?
我想補充,'disqus_developer'是[不再支持的配置可變](http://help.disqus.com/customer/portal/articles/472098-javascript-configuration-variables)。有關替代方法,請參閱http://help.disqus.com/customer/portal/articles/1053796-best-practices-for-staging-development-and-preview-sites。 – iain