How to develop Wechat Public platform one-click pay attention to Wechat Public platform account
This article is about how to develop a one-click WeChat public platform account. Xiaobian thinks it is quite practical, so share it with everyone for reference. Let's follow Xiaobian and have a look.
1. Use HTTP protocol
[Invalid]
Click to follow Fangbei Studio.
Use of Weixin Protocol
Method 1:[Invalid]
Click to follow Fangbei Studio
Method 2:[Invalid]
Click to follow Fangbei Studio
Method 3: Android works, Apple doesn't work
Click to follow Fangbei Studio
3. Use JavaScript code
[Only valid for official domain names]
var addWxContact = function(wxid, cb){ if (typeof WeixinJSBridge == 'undefined') return false; WeixinJSBridge.invoke('addContact', { webtype: '1', username: 'gh_204936aea56d' }, function(d) { //returns the value d.err_msg, d also has an attribute err_desc // add_contact:cancel User cancel // add_contact: fail // add_contact:ok Follow success // add_contact:added already followed WeixinJSBridge.log(d.err_msg); cb && cb(d.err_msg); });};
IV. Special use for some accounts
[Invalid]
https://open.weixin.qq.com/subscribe? appid=wxb629c48b653e
5. DNS only
[Effective on Cake Handsome Rich]
After decoding,
https://login.weixin.qq.com/l/E0LsxoTaRxC_HM Thank you for reading! About "WeChat public platform how to develop a one-click attention WeChat public platform account" This article has been shared here. I hope the above content can be of some help to everyone, so that everyone can learn more knowledge. If you think the article is good, you can share it for more people to see!