您的位置:首页 > 其它

百度分享插件的使用

2017-08-17 16:04 204 查看
页面效果:



//样式部分
<style type="text/css">
/*百度分享按钮样式*/
.bdsharebuttonbox{
border:none;
outline:none;
display:inline;
}
.bdsharebuttonbox a.bds_more {
padding:5px 5px 5px 30px;
font-size:14px;
color:#ff9a00;
background-position:0 6px;
float:none;
margin:1px 0px 1px;
}
.bdsharebuttonbox a.bds_more:hover {color:#ff9a00;}
</style>


//页面部分
<div class="bdsharebuttonbox"><a href="#" class="bds_more" data-cmd="more">分享</a></div>


//js部分
<script>
window._bd_share_config={
"common":{
"bdSnsKey":{},
"bdText":"",
"bdMini":"2",
"bdMiniList":false,
"bdPic":"",
"bdStyle":"0",
"bdSize":"16"
},
"share":
{}
};
with(document)0[(getElementsByTagName('head')[0]||body).appendChild(createElement('script')).src='http://bdimg.share.baidu.com/static/api/js/share.js?v=89860593.js?cdnversion='+~(-new Date()/36e5)];
</script>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: