diff --git a/_includes/disqus.html b/_includes/disqus.html index fd05ba0..dd80975 100644 --- a/_includes/disqus.html +++ b/_includes/disqus.html @@ -1,17 +1,17 @@ -{% if site.disqus %} +{%- if site.disqus -%}
-
- - + var disqus_url = url_parts[0]; + (function() { + var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true; + dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js'; + (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq); + })(); + +
-{% endif %} +{%- endif -%}