Skip to content

Commit

Permalink
updated disqus script to the latest version
Browse files Browse the repository at this point in the history
  • Loading branch information
carlwoodhouse committed Jul 13, 2016
1 parent 177c788 commit 2033797
Showing 1 changed file with 13 additions and 12 deletions.
25 changes: 13 additions & 12 deletions Views/Parts.Disqus.cshtml
@@ -1,14 +1,15 @@
<h2>Comments</h2>
<div id="disqus_thread"></div>
<script type="text/javascript">
var disqus_shortname = '@Model.Shortname';
(function () {
var dsq = document.createElement('script');
dsq.type = 'text/javascript';
dsq.async = true;
dsq.src = 'http://' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
})();
</script>
<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
<noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript" rel="nofollow">comments powered by Disqus.</a></noscript>
@using(Script.Foot()) {
<script>
(function() {
var d = document, s = d.createElement('script');
var sn = '@Model.Shortname';
s.src = '//' + sn + '.disqus.com/embed.js';
s.setAttribute('data-timestamp', +new Date());
(d.head || d.body).appendChild(s);
})();
</script>
}

0 comments on commit 2033797

Please sign in to comment.