新闻建站cms系统、政府cms系统定制开发

广州网站建设公司-阅速公司

asp.net新闻发布系统、报纸数字报系统方案
/
http://www.ysneo.com/
广州网站建设公司
您当前位置:首页>网站技术

网站技术

script中js延迟加载示例

发布时间:2013/11/25 15:00:10  作者:Admin  阅读:311  

广告:阿里云采购优惠专区

基于jquery,上面是google代码,下面是百度代码

<script type="text/javascript">

var _gaq = _gaq || [];

_gaq.push(['_setAccount', 'UA-0000000000-1']);

_gaq.push(['_setDomainName', 'chinadoweb.com']);

_gaq.push(['_trackPageview']);

(function() {

var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.setAttribute('async', true);

ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';

var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);

})();

</script>

<div class="hide">

<script type="text/javascript">

(function() {

var baidu = document.createElement('script');

baidu.type = 'text/javascript';

baidu.setAttribute('async', true);

baidu.src = ('https:' == document.location.protocol ? 'https://' : 'http://') + 'hm.baidu.com/h.js?9af37----------';

var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(baidu, s);

})();

</script>

广告:阿里云新人采购专场

相关文章
script
js
cms新闻系统购买咨询
扫描关注 广州阅速软件科技有限公司
扫描关注 广州阅速科技