小程序中添加客服按钮contact-button

时间:2022-02-08 08:46:07

小程序的客服系统,是微信做的非常成功的一个功能,开发者可以很方便的通过一行代码,就可实现客服功能。

1. 普通客服按钮添加

 <button open-type='contact' session-from=''>客服-联系我们</button>

小程序中添加客服按钮contact-button

2. 悬浮客服按钮添加,图片自定义

小程序中添加客服按钮contact-button

大家看地图的有个客服图片图片资源。大家去iconfont 网站去找一个就可以了

index.wxml

<button class="kf_button" open-type="contact" session-from="weapp">
<image class="kf_image" src="../../resources/img/kf.PNG"></image>
</button>

index.wxss

.kf_button{
background-color: rgba(, , , );
border: 0px;
height: 100rpx;
right: ;
bottom: 20rpx;
position: fixed;
}
.kf_button::after{
border: 0px;
}
.kf_image{
z-index: ;
width: 100rpx;
height: 100rpx;
}

芝麻小客服 小程序关注公众号的电商多客服系统 http://xiaokefu.hotapp.cn