This project is read-only.

Disqus comments with 2.0 Final (also RC)

Topics: ASP.NET 2.0, Business Logic Layer, Themes
Jan 2, 2011 at 9:31 AM

I've just upgraded BE.NET to the final 2.0 version (was running RC for the past couple of weeks as well). In both versions, with Disqus comments enabled, I was getting the following notification when accessing post comments:

"You are seeing this message because developer mode is on. One or more of the following embed variables are missing: disqus_identifier, disqus_shortname. They are recommended for stability reasons, read about them in the Disqus Developer Docs"

Scanning for new reactions didn't work either.

However, modifying a post file template (e.g. post.aspx) to the following (to include required variables):

<script type="text/javascript">
    var disqus_url = '<%= Post.AbsoluteLink %>';
    var disqus_identifier = '<%= Post.Id %>';
    var disqus_shortname = '<%=BlogEngine.Core.BlogSettings.Instance.DisqusWebsiteName %>';
    var disqus_developer = '<%= BlogSettings.Instance.DisqusDevMode ? 1 : 0 %>';
    (function() {
        var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
        dsq.src = 'http://<%=BlogSettings.Instance.DisqusWebsiteName %>';
        (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);

... seemed to have resolved the issue - the reactions are shown, but there still are some issues with showing the correct number of reactions in the other places I didn't go into.

I believe this issue is a result of a recent Disqus API changes... Anybody have a more complete solution?

Jan 2, 2011 at 3:22 PM

I have the same problem (warning message) in BE 2.0.