console
3 document.addEventListener('WeixinJSBridgeReady', function onBridgeReady() {
4 window.shareData = {
5 "timeLineLink": "http://www.baidu.com",
6 "sendFriendLink": "http://www.baidu.com",
7 "weiboLink": "http://www.baidu.com",
8 "tTitle": "广东南粤e+直销银行,简化金融服务为您智能理财,让您的生活更轻松!",
9 "tContent": "简化金融服务为您智能理财,让您的生活更轻松!",
10 "fTitle": "广东南粤e+直销银行",
11 "fContent": "简化金融服务为您智能理财,让您的生活更轻松!",
12 "wContent": "简化金融服务为您智能理财,让您的生活更轻松!"
13 };
14
15 WeixinJSBridge.on('menu:share:appmessage', function (argv) {
16 WeixinJSBridge.invoke('sendAppMessage', {
17 "img_url": "http://i.thsi.cn/iwencai/xuangu/images/ths-icon.png",
18 "img_width": "32",
19 "img_height": "32",
20 "link": window.shareData.sendFriendLink,
21 "desc": window.shareData.fContent,
22 "title": window.shareData.fTitle
23 }, function (res) {
24 _report('send_msg', res.err_msg);
25 })
26 });
27
28 WeixinJSBridge.on('menu:share:timeline', function (argv) {
29 WeixinJSBridge.invoke('shareTimeline', {
30 "img_url": "http://i.thsi.cn/iwencai/xuangu/images/ths-icon.png",
31 "img_width": "32",
32 "img_height": "32",
33 "link": window.shareData.timeLineLink,
34 "desc": window.shareData.tContent,
35 "title": window.shareData.tTitle
36 }, function (res) {
37 _report('timeline', res.err_msg);
38 });
39 });
40
41 }, false)
<div>testtttt</div>