Get the App
SLTechnology News&Howtos  ›  Development  › 

What are the official Wechat interfaces for php?

Shulou Source: shulou.com Published: 2022-06-03 08:53:19 11月15日 Update

This article mainly explains "what are the official Wechat interfaces of php", interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Now let the editor take you to learn "what are the official Wechat interfaces for php"?

Wechat entry binding, Wechat event handling, and Wechat API all operations are included in these files.

Contents include: Wechat shake interface / Wechat multi-customer service interface / WeChat Pay interface / WeChat red packet interface / Wechat card voucher interface / Wechat shop interface / JSAPI

JSAPI API test wx.config ({debug: true, appId:', timestamp:, nonceStr:', signature:', jsApiList: [/ / all API to be called should be added to this list 'onMenuShareTimeline',' onMenuShareAppMessage']}) Wx.ready (function () {/ / call API wx.onMenuShareAppMessage here ({title: 'son of the Internet', desc: 'when I was growing up, I slowly realized that everything around me, everything people told me, the so-called things that are meant to be like this, they don't have to be like this, things can change. More importantly, since something is wrong, it should be changed.' , link: 'http://movie.douban.com/subject/25785114/', imgUrl:' https://cache.yisu.com/upload/information/20201209/266/41237.jpg', trigger: function (res) {/ / do not try to use ajax asynchronous request in trigger to modify the content of this share, because the client sharing operation is a synchronous operation At this time, the return packet using ajax has not yet returned alert ('user click to send to friends') }, success: function (res) {alert ('shared');}, cancel: function (res) {alert ('cancelled');}, fail: function (res) {alert (JSON.stringify (res));}}) Wx.onMenuShareTimeline ({title: 'son of the Internet', link: 'http://movie.douban.com/subject/25785114/', imgUrl:' https://cache.yisu.com/upload/information/20201209/266/41237.jpg', trigger: function (res) {/ / do not try to modify the content of this share using ajax asynchronous request in trigger Because the client sharing operation is a synchronous operation, the response packet using ajax has not yet returned alert ('users click to share to moments') }, success: function (res) {alert ('shared');}, cancel: function (res) {alert ('cancelled');}, fail: function (res) {alert (JSON.stringify (res));});}) Var readyFunc = function onBridgeReady () {document.querySelector ('# batchAddCard') .addEventListener ('click',function (e) {WeixinJSBridge.invoke (' batchAddCard', {"card_list": []}, function (res) {alert (res.err_msg + "_" + res.card_list);});}) } if (typeof WeixinJSBridge = "undefined") {document.addEventListener ('WeixinJSBridgeReady', readyFunc, false);} else {readyFunc ();}

Tags: Interfaces information users parameters characters strings content devices pages arrays queries generation data methods formats menus official people friends events Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Xiaomi Apple Shulou Technology Shulou Tech Info MariaDB