Created
September 11, 2010 08:28
-
-
Save lfborjas/574990 to your computer and use it in GitHub Desktop.
The generic code to use disqus comments, adapted to haml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:javascript | |
var disqus_shortname = 'YOUR-SITE'; | |
(function () { | |
var s = document.createElement('script'); s.async = true; | |
s.src = 'http://disqus.com/forums/YOUR-SITE/count.js'; | |
(document.getElementsByTagName('HEAD')[0] || document.getElementsByTagName('BODY')[0]).appendChild(s); | |
}()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#disqus_thread | |
:javascript | |
(function() { | |
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true; | |
dsq.src = 'http://YOUR-SITE.disqus.com/embed.js'; | |
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq); | |
})(); | |
%noscript | |
Please enable JavaScript to view the | |
%a{:href=>"http://disqus.com/?ref_noscript=YOUR-SITE"} comments | |
powered by Disqus. | |
%a.dsq-brlink{:href=>"http://disqus.com"} | |
comments powered by | |
%span.logo-disqus Disqus |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment