zoukankan      html  css  js  c++  java
  • 微信小程序封装请求接口

    var rootDocment = 'https://123.com';//你的域名
    function postData(url, data, cb) {

    wx.request({

          url: rootDocment + url,
          data: data,
          method: 'post',
          success: function (res) {
            return typeof cb == "function" && cb(res)
          },
          fail: function () {
            return typeof cb == "function" && cb(false)
          }
        })
    }
  • 相关阅读:
    20210131
    20210130
    20210129
    20210128
    20210127
    例3-7
    例3-5
    例3-4
    例3-3
    例3-2
  • 原文地址:https://www.cnblogs.com/caoyuna/p/11478786.html
Copyright © 2011-2022 走看看