// succ.wxml <view>WIFI ssid:{{wifissid}}</view> <view>WIFI bssid:{{wifiBssid}}</view> // succ.js var app = getApp() Page({ data: { wifissid: '', // WIFI ssid wifiBssid: '' // WIFI bssid }, onLoad: function (e) { // 获取参数 var that = this; wx.getConnectedWifi({ success: function(e){ that.setData({ wifissid: e.wifi.SSID, wifiBssid: e.wifi.BSSID }) } }) } })
来源:博客园
作者:aaronthon
链接:https://www.cnblogs.com/aaronthon/p/11673471.html