On May 17, 2021, wechat iOS released version 8.0.6. Although wechat’s update log was perfunctory as always, in fact, there was a huge upgrade hidden inside.

What’s the upgrade? Small programs already support long press to identify micro, micro.

How powerful is this little upgrade? We need to understand before having this ability, small program drainage users add micro, micro process. Take Watsons as an example:

The first step is to direct the user to click into a customer service session

The second step requires the user to send a small program to the customer service session

The third step: send the company micro QR code in the customer session, and the user long press scan code to pay attention

It’s hard to expect customers to do so much, and you can expect poor results. In contrast, the efficiency of long scan code concerns do not know how many times higher, rough estimate, the two different ways to add micro, micro efficiency compared to may have more than ten times the difference.

Experience small program scan code plus a micro:

Experience scanning code in small program to add enterprise micro:

How can developers take advantage of this ability? Here are three actual combat schemes:

The preview qr code

The applets used are as follows:

wx.previewImage({
  current: ' '.// HTTP link for the current display image
  urls: [] // List of HTTP links for images to preview
})
Copy the code

The effect is as follows:

The disadvantage of doing this is to open the page is always a picture or more pictures, the picture can only put a TWO-DIMENSIONAL code. If you put both qr codes in the same picture, the last qr code will be recognized. For example, the following small program, I will enterprise micro, micro in a picture, long press recognition is a micro (this is related to the size of the mobile phone screen, the larger screen or can recognize two codes) :

Embed qr code in webView

At present, you can also put the qr code of the enterprise micro or micro in the public account tweet. Small programs directly webview to open tweets, long press to scan the QR code in tweets can also identify and follow. The code is very simple as follows:

<web-view src="Links to tweets from public accounts."></webview>
Copy the code

The effect is as follows:

The only thing to note here is that the public account must be associated with the applet, otherwise the applet’s WebView won’t open the tweet. The associated operation can be operated in the background of the public account.

The image tag displays the QR code

Directly use the image label to display the TWO-DIMENSIONAL code, the code is as follows:

<image src="Qr code picture address" show-menu-by-longpress="true"></image>
Copy the code

The key point here is that show-menu-by-longpress=”true” must be added, otherwise long presses will not work.

This looks good and doesn’t have the limitations of the first option, so why put it at the end? This is because the current version 8.0.6 has some bugs, as follows:

Click to open the card, there will be no response. The official statement also confirms that this is a bug in the current version and promises to fix it in the next version. By the time you read this, the bug will have been fixed.

Frank has tested the above three methods in wechat iOS 8.0.6 version and Android 8.0.3 version. If you can’t open qiweiweiwei by clicking the small program above, please check your wechat version first.

Public qr code how to do

At present, the public qr code is still not in the original small program long press identification. Long press identification can only be done in webView mode. As follows:

If you think it is helpful to you, please give Frank a thumbs-up and share it with your friends. In this way, Frank will also have the motivation to update. Thank you