Home > Web Front-end > JS Tutorial > body text

Added online customer service function to WeChat mini program

php中世界最好的语言
Release: 2018-05-15 10:52:38
Original
5354 people have browsed it

This time I will bring you the function of contacting online customer service in the WeChat mini program. What are the precautions for adding the function of contacting online customer service in the WeChat mini program. The following is a practical case, let's take a look.

1. Add a normal customer service button

 <button open-type=&#39;contact&#39; session-from=&#39;&#39;>客服-联系我们</button>
Copy after login

##2. Add a floating customer service button and customize the picture

If you look at the map, there is a customer service picture resource. Just go to the iconfont website to find one

index.wxml

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

.kf_button{
 background-color: rgba(255, 255, 255, 0);
 border: 0px;
 height: 100rpx;
 right: 0;
 bottom: 20rpx;
 position: fixed;
}
.kf_button::after{
 border: 0px;
}
.kf_image{
 z-index: 9999;
 width: 100rpx;
 height: 100rpx;
}
Copy after login
I believe you have mastered the method after reading the case in this article, and there will be more exciting things. Please pay attention to other related articles on php Chinese website!

Recommended reading:

Vue implements the steps to implement the PopupWindow component

jQuery implements the electronic clock function step-by-step analysis

The above is the detailed content of Added online customer service function to WeChat mini program. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!