-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
13 additions
and
20 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,15 @@ | ||
{% if confObj.duoshuo %} | ||
<div id="comments" class="clearfix"> | ||
{% if confObj.changyan %} | ||
<div id="comments" class="comments-area"> | ||
<div id="respond" class="comment-respond"> | ||
<!-- 多说评论框 start --> | ||
<div class="ds-thread" data-thread-key="{{ blog.blogId }}" data-title="{{ blog.title }}" data-url="{{ site.url }}{{ blog.siteURL }}"></div> | ||
<!-- 多说评论框 end --> | ||
<!-- 多说公共JS代码 start (一个网页只需插入一次) --> | ||
<script type="text/javascript"> | ||
var duoshuoQuery = {short_name:"{{ confObj.duoshuo }}"}; | ||
(function() { | ||
var ds = document.createElement('script'); | ||
ds.type = 'text/javascript';ds.async = true; | ||
ds.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') + '//static.duoshuo.com/embed.js'; | ||
ds.charset = 'UTF-8'; | ||
(document.getElementsByTagName('head')[0] | ||
|| document.getElementsByTagName('body')[0]).appendChild(ds); | ||
})(); | ||
</script> | ||
<!-- 多说公共JS代码 end --> | ||
</div><!-- #respond --> | ||
</div> | ||
<!--PC和WAP自适应版--> | ||
<div id="SOHUCS" sid="{{ blog.blogId }}" ></div> | ||
<script type="text/javascript"> | ||
(function(){ | ||
var appid = "{{ confObj.changyan }}"; | ||
var conf = 'prod_1fb21904f797de208dd3e1bee418b76e'; | ||
var width = window.innerWidth || document.documentElement.clientWidth; | ||
if (width < 960) { | ||
window.document.write('<script id="changyan_mobile_js" charset="utf-8" type="text/javascript" src="http://changyan.sohu.com/upload/mobile/wap-js/changyan_mobile.js?client_id=' + appid + '&conf=' + conf + '"><\/script>'); } else { var loadJs=function(d,a){var c=document.getElementsByTagName("head")[0]||document.head||document.documentElement;var b=document.createElement("script");b.setAttribute("type","text/javascript");b.setAttribute("charset","UTF-8");b.setAttribute("src",d);if(typeof a==="function"){if(window.attachEvent){b.onreadystatechange=function(){var e=b.readyState;if(e==="loaded"||e==="complete"){b.onreadystatechange=null;a()}}}else{b.onload=a}}c.appendChild(b)};loadJs("http://changyan.sohu.com/upload/changyan.js",function(){window.changyan.api.config({appid:appid,conf:conf})}); } })(); </script> | ||
</div> | ||
</div> | ||
{% endif %} |