Home Web Front-end JS Tutorial How to add a customer service button to the WeChat mini program

How to add a customer service button to the WeChat mini program

Jun 01, 2018 pm 05:39 PM
customer service Applets button

This time I will show you how to add a customer service button to the WeChat mini program and what are the precautions for adding a customer service button to 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:

How to make vue-baidu-map to enter the page and automatically locate it


How to use Vue2.0 Call the camera to take pictures

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

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

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Change the power button action on Windows 11 [5 Tips] Change the power button action on Windows 11 [5 Tips] Sep 29, 2023 pm 11:29 PM

The power button can do more than shut down your PC, although this is the default action for desktop users. If you want to change the power button action in Windows 11, it's easier than you think! Keep in mind that the physical power button is different from the button in the Start menu, and the changes below won't affect the operation of the latter. Additionally, you'll find slightly different power options depending on whether it's a desktop or laptop. Why should you change the power button action in Windows 11? If you put your computer to sleep more often than you shut it down, changing the way your hardware power button (that is, the physical power button on your PC) behaves will do the trick. The same idea applies to sleep mode or simply turning off the display. Change Windows 11

Where to find Douyin customer service Where to find Douyin customer service Mar 28, 2024 pm 02:13 PM

1. Open the Douyin app, click [Me] in the lower right corner, and click the [Three Stripes] icon in the upper right corner. 2. Select [My Customer Service] in the right menu bar and click the [Online Customer Service] button. 3. Select the type of question or order you want to consult, click [Online Consultation], select the question you want to consult or enter the question directly.

iOS 17: How to organize iMessage apps in Messages iOS 17: How to organize iMessage apps in Messages Sep 18, 2023 pm 05:25 PM

In iOS 17, Apple not only added several new messaging features, but also tweaked the design of the Messages app to give it a cleaner look. All iMessage apps and tools, such as the camera and photo options, can now be accessed by tapping the "+" button above the keyboard and to the left of the text input field. Clicking the "+" button brings up a menu column with a default order of options. Starting from the top, there's camera, photos, stickers, cash (if available), audio, and location. At the very bottom is a "More" button, which when tapped will reveal any other installed messaging apps (you can also swipe up to reveal this hidden list). How to reorganize your iMessage app You can do this below

How to use Vue to implement button countdown effects How to use Vue to implement button countdown effects Sep 21, 2023 pm 02:03 PM

How to use Vue to implement button countdown effects With the increasing popularity of web applications, we often need to use some dynamic effects to improve user experience when users interact with the page. Among them, the countdown effect of the button is a very common and practical effect. This article will introduce how to use the Vue framework to implement button countdown effects and give specific code examples. First, we need to create a Vue component that contains a button and countdown function. In Vue, a component is a reusable Vue instance, and a view will

Why won't my laptop start up after pressing the power button? Why won't my laptop start up after pressing the power button? Mar 10, 2024 am 09:31 AM

There could be several reasons why your Windows laptop won't boot. Memory failure, dead battery, faulty power button, or hardware issues are all common causes. Here are some solutions to help you resolve this issue. Laptop won't turn on after pressing the power button If your Windows laptop still won't turn on after pressing the power button, here are some steps you can take to resolve the issue: Is your laptop fully charged? Perform a hard reset to clean your laptop Reseat the memory Transparent CMOS type battery Take your laptop for repair. 1] Is your laptop fully charged? The first thing to do is to check if your laptop is fully charged. Laptop won't start if battery is drained

How to restart your iPhone (all models) How to restart your iPhone (all models) Jul 18, 2023 pm 04:57 PM

How to Restart iPhone with Face ID Follow the steps below to learn how to restart iPhone with Face ID. This method is suitable for restarting iPhone14, iPhone13, iPhone12, iPhone11, iPhoneXS and iPhoneX. 1. Press and hold the power button and either volume button until the "Slide to power off" option appears. 2. Drag the slider to the right and your iPhone will turn off. 3. Now, wait for 30 seconds and hold the power button until the Apple logo appears on the screen. How to Restart iPhone Using TouchID Before iPhoneX was released, restarting iPhone was easier than current models because

What does iPhone 16 look like? What changes are there in iPhone 16? What does iPhone 16 look like? What changes are there in iPhone 16? Apr 07, 2024 pm 05:10 PM

After the release of the iPhone 15 series, there have been constant revelations about the appearance and configuration of Apple’s new iPhone 16. What does iPhone 16 look like? Is there any improvement in iPhone 16? Recently, an overseas blogger showed off the design of the iPhone 16 series. The overall design is basically the same as the iPhone 15 series. As you can see from the picture, the entire iPhone 16 series is equipped with a new "shoot" button as standard, allowing users to take photos more conveniently. In addition, other design details are still unknown. The message shows that this new button will be used to shoot videos and is located below the power button. Previous news has mentioned that it may be a capacitive solid-state button, but recent reports indicate that it should still be a

Implement card flipping effects in WeChat mini programs Implement card flipping effects in WeChat mini programs Nov 21, 2023 am 10:55 AM

Implementing card flipping effects in WeChat mini programs In WeChat mini programs, implementing card flipping effects is a common animation effect that can improve user experience and the attractiveness of interface interactions. The following will introduce in detail how to implement the special effect of card flipping in the WeChat applet and provide relevant code examples. First, you need to define two card elements in the page layout file of the mini program, one for displaying the front content and one for displaying the back content. The specific sample code is as follows: &lt;!--index.wxml--&gt;&l

See all articles