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)
}
})
}
原文地址:https://www.cnblogs.com/caoyuna/p/11478786.html
时间: 2024-10-10 13:37:05