Skip to content

Commit

Permalink
Move Disqus script inside conditional to avoid <noscript> text from a…
Browse files Browse the repository at this point in the history
…ppearing on pages that have comments disabled
  • Loading branch information
mmistakes committed Jan 22, 2015
1 parent c25fad7 commit 7956577
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
3 changes: 1 addition & 2 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ logo: site-logo.png
search: true
url: http://localhost:4000


# Jekyll configuration

permalink: /:categories/:title/
Expand Down Expand Up @@ -50,4 +49,4 @@ owner:
verify:
ad-client:
ad-slot:
bing-verify:
bing-verify:
4 changes: 0 additions & 4 deletions _includes/scripts.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,3 @@
})();
</script>
{% endif %}

{% if page.comments or site.comments %}
{% include disqus_comments.html %}
{% endif %}
5 changes: 4 additions & 1 deletion _layouts/post.html
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,10 @@ <h1 class="entry-title">{% if page.headline %}{{ page.headline }}{% else %}{{ pa
</footer>
<div class="entry-content">
{{ content }}
{% if (site.owner.disqus-shortname and page.comments) or site.comments %}<div id="disqus_thread"></div><!-- /#disqus_thread -->{% endif %}
{% if (site.owner.disqus-shortname and page.comments) or site.comments %}
<div id="disqus_thread"></div><!-- /#disqus_thread -->
{% include disqus_comments.html %}
{% endif %}
</div><!-- /.entry-content -->
</div><!-- /.entry-wrapper -->
<nav class="pagination" role="navigation">
Expand Down

0 comments on commit 7956577

Please sign in to comment.