dataForWx = { "link": "http://evp.51job.com/2020/kcc/", //微信链接 "imgUrl": "http://evp.51job.com/2020/kcc/logo.png", //微信logo "title":"金佰利中国2020校园招聘", //微信标题 "desc":"年轻有为来KC", }; wx.config({ debug: false, appId: 'wx16a30236aa49a0d1', timestamp: 1730777478, nonceStr: 'MfXrVk4nfdwPWmsJ', signature: '552e4ea6b37ba89d6fde1a8c5f7b52b7595f3677', jsApiList: [ 'onMenuShareAppMessage', 'onMenuShareTimeline' ] }); wx.ready(function() { wx.onMenuShareAppMessage({ title: dataForWx.title, desc: dataForWx.desc, link: dataForWx.link, imgUrl: dataForWx.imgUrl, fail: function (res) {f alert(JSON.stringify(res)); } }); wx.onMenuShareTimeline({ title: dataForWx.title, link: dataForWx.link, imgUrl: dataForWx.imgUrl, fail: function (res) { alert(JSON.stringify(res)); } }); });