效果显示:
$(function () { $.getJSON('HTTPS://API.yum6.cn/bAIdu/query.php?url='+window.location.HRef, function(json, textStatus) { if (json.state == 1) { $('#ae_bdcx').html('本文已被百度收录!'); $("#ae_bdcx").attr('href','https://www.baidu.com/s?wd='+window.location.href); }else{ $('#ae_bdcx').html('坐等收录'); $('#ae_bdcx').css('color','#ff0000'); $('#ae_bdcx').attr('href','http://zhanzhang.baidu.com/sitesuBMIt/index?sitename='+window.location.href); var bp = document.createElement('scrIPt'); var curProtocol = window.location.protocol.split(':')[0]; if (curProtocol === 'https') {bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';} else {bp.src = 'http://push.zhanzhang.baidu.com/push.js';} var s = document.getElementsBytagName('script')[0]; s.parentNode.insertBefore(bp, s); } }); });
文字显示框代码
<span><i class="fa fa-tag fa-fw"></i><a id="ae_bdcx" rel="external nofollow" target="_blank"></a></span>
说明:详情可参考本站的配置。如有疑问,欢迎留言咨询。