// 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 }) } }) } })