summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrekado <rekado@elephly.net>2015-08-16 05:10:38 +0200
committerrekado <rekado@elephly.net>2015-08-17 22:56:01 +0200
commitb6ae365752ab796d36c7ad9fb20e2d879c8a2e16 (patch)
treed6b266ea3332b5d1c167a9d2a9c474ae5658282f
parente6c359806c8cdbf52e3ee0ddd08817433f869986 (diff)
js: put "loadComments" stuff in own file.
-rw-r--r--static/js/loadComments.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/static/js/loadComments.js b/static/js/loadComments.js
new file mode 100644
index 0000000..cce27dc
--- /dev/null
+++ b/static/js/loadComments.js
@@ -0,0 +1,7 @@
+var loadComments = function() {
+ var el = document.getElementById("loadComments");
+ el.parentNode.removeChild(el);
+ var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
+ dsq.src = 'http://elephly.disqus.com/embed.js';
+ (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
+};