Home > Article > WeChat Applet > WeChat Mini Program Example: Implementation Code of Pop-up Window in WeChat Mini Program
The content of this article is about the code implementation of gzip decompression in js. It has certain reference value. Friends in need can refer to it. I hope it will be helpful to you.
The WeChat applet needs to give the user some prompts when interacting with the user, such as whether to request data, etc. At this time, using pop-up windows is a better method.
Fortunately, the WeChat applet provides We provide an API wx.showToast
success: function (res) { app.globalData.allData = res.data.datas; if (res.data.status == 200) { wx.showToast({ title: '数据搜索成功', icon: 'success', duration: 1500 }) self.setData({ list: res.data.datas }) } else { wx.showToast({ title: '未搜索到数据', icon: 'loading', duration: 1500 }) } }
Related recommendations:
How to jump pages in the WeChat applet
How to set global variables (code) in the WeChat mini program
The above is the detailed content of WeChat Mini Program Example: Implementation Code of Pop-up Window in WeChat Mini Program. For more information, please follow other related articles on the PHP Chinese website!