标签归档:javascript

jiathis分享书签的实现原理

我们只要把下面的js代码放到收藏栏中,就会点击弹出jiathis分享表单,我们就可以分享任意网址了。

javascript: (function() {
    var w = window,
        d = document,
        s;
    if (!w.jiathis) {
        w.jiathis = 1;
        s = d.createElement('script');
        s.src = 'http://v3.jiathis.com/code/j.js';
        d.getElementsByTagName('head')[0].appendChild(s);
        s = null
    } else {
        $CKE.center()
    }
})()

这段代码的意思就是在当前页面插入一段代码,这段代码来自http://v3.jiathis.com/code/j.js

查看这个代码我们可以看到:

/* (c) 2016 JiaThis Inc. 0412*/
eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('4 Z={b1:"2g://L.1m.7",1v:"2g://b0.1m.7/aY",2H:"2g://s.1m.7",aS:1j,4o:[],aR:{\'aQ\':\'微信,aL,1G,1G.1U.7\',\'aJ\':\'微博,aI,aG.7\',\'aC\':\'1y好友,aB,aA,az.1U.7\',\'ay\':\'1y空间,ap,ao.am.1U.7\',\'aj\':\'复制网址,ai\',\'ah\':\'收藏夹,ag\',\'af\':\'打印,ae\',\'ad\':\'邮件,ac\',\'ab\':\'人人网,aa,L.a8.7\',\'a7\':\'开心网,a5,L.a4.7\',\'a3\':\'印象笔记,9Y\',\'9V\':\'领英,9U\',\'9T\':\'飞信,9S,9M.9K.9J.18\',\'9I\':\'豆瓣,J,L.3E.7\',\'9H\':\'9G,9F,t.9E\',\'9D\':\'9y,3S,L.3S.7\',\'9u\':\'一键分享,9t\',\'9s\':\'猜你喜欢,9r\',\'9m\':\'易信,9l,L.9k.9h\',\'9g\':\'花瓣网,9e,99.7\',\'97\':\'腾讯微博,95,t.1U.7\',\'94\':\'93+,92,91.12.4D.7\',\'8Y\':\'阿里巴巴,8T,L.8R.7\',\'8Q\':\'朋友网,8P,1V.8O.7\',\'8N\':\'麦库记事,8M\',\'8L\':\'百度搜藏,8K,8J.2h.7\',\'8I\':\'8H邮箱,8G,3t.4D.7\',\'8D\':\'有道云笔记,8C,8B.3x.7\',\'8A\':\'天涯社区,8z,3A.8y.18\',\'8x\':\'百度贴吧,8w,8v.2h.7\',\'8s\':\'轻笔记,8r\',\'8q\':\'凤凰微博,8p,t.8o.7\',\'8n\':\'饭否,8m,8l.7\',\'8k\':\'明道,8j,L.8h.7\',\'8g\':\'豆瓣9点,8e,9.3E.7\',\'8d\':\'谷歌,8c\',\'8b\':\'谷歌8a,89\',\'84\':\'有道书签,83,3W.3x.7\',\'82\':\'1y书签,81,3W.1U.7\',\'80\':\'1X,7Z\',\'7X\':\'7W,4K\',\'7S\':\'堆糖,7R,L.7P.7\',\'7N\':\'摇篮微博,7M\',\'7K\':\'百度空间,7J,7I.4h.2h.7\',\'7F\':\'7E邮箱,7D\',\'7C\':\'雪球,7B,7A.7\',\'7y\':\'和讯,7x,7w.4v.7\',\'7v\':\'7u邮箱,7t\',\'7r\':\'4E邮箱,7p\',\'7o\':\'翼友圈,7n,7k.4E.18\',\'7h\':\'人民微博,7g,t.7f.7.18\',\'7d\':\'新华微博,7b\',\'7a\':\'谷歌翻译,79\',\'78\':\'推他,76,L.75.7\',\'74\':\'猫扑推客,73,72.71.7\',\'6Z\':\'美丽说,6Y\',\'6X\':\'蘑菇街,6W,6V.18\',\'6U\':\'赶牛网,6T,L.6S.7\',\'6R\':\'6O网,6N,3A.6M.18\',\'6L\':\'雷猴网,6K,6D.7\',\'6C\':\'和讯微博,6B,t.4v.7\',\'6A\':\'游戏江湖,6z,4h.6y.7\',\'6x\':\'法律微博,6w\',\'6v\':\'6u,3C,L.3C.7\',\'6t\':\'6s,6r\',\'6q\':\'6p,3H,L.3H.7\',\'6o\':\'6n,6m,6l.7\',\'6k\':\'财迷,6j,t.6i.7\',\'6h\':\'6g+分享,6f,6e,i.6d.7.18\',\'6c\':\'挖客网,6b\',\'6a\':\'创业邦,67,u.66.18\',\'65\':\'救救地球,64\',\'63\':\'抽屉网,62\',\'61\':\'递客网,60,L.5Y.18\',\'5V\':\'易集网,5T,L.5S.7\',\'5Q\':\'5O在线转换,5N\',\'5M\':\'友好打印,5L\',\'5K\':\'5J验证,5I\',\'5H\':\'5F.4d,5E,5D.4d\',\'5C\':\'5B,4i,4i.7\',\'5A\':\'5z.4l,3t.4l\',\'5y\':\'5v,5u\',\'5t\':\'5s,5r\',\'5q\':\'5p,5o\',\'5n\':\'5m,5l\',\'5k\':\'5i,5h\',\'5g\':\'5f,5e\',\'5b\':\'5a,59\',\'58\':\'4Q.4J,4L.4J\',\'7U\':\'4M,4N\',\'4O\':\'4P,4I,L.4I.7\',\'4R\':\'4S 4T,4U\',\'4V\':\'4W,4X\',\'4Y\':\'4Z,51\',\'52\':\'53,54\',\'55\':\'56,57\'}};(q(){4 d=H,31=d.5c=="5d",1b=d.4C,J=d.2f,m=4z.5j,2Y=!!d.4x,4w=1C.1q.4t(),1x=d.1S(\'1x\')[0]||1b,4p=q(){I{h:(31?1b:J).5w,w:(31?1b:J).5x}},2b=q(){I{t:m(1b.2a,J.2a),l:m(1b.2P,J.2P)}},3u=q(a){4 r={t:0,l:0},4c=/5G/.1r(4w),1u=q(t,l){r.l+=l,r.t+=t},p=a,2I=2b();n(a&&a!=J){n(a.46){4 b=a.46();1u(b.V+2I.t-1b.5P,b.1f+2I.l-1b.5R)}y{4 c=d.5U;40(p){1u(p.5W,p.5X);4 e=c.5Z(p,2B);n(4c){4 f=1k(e.2z(\'1c-1f-Y\'),10)||0,2w=1k(e.2z(\'1c-V-Y\'),10)||0;1u(2w,f);n(p!=a&&e.2z(\'2v\')!=\'68\')1u(2w,f)}p=p.69}p=a.2u;40(p&&p!=J){1u(-p.2a,-p.2P);p=p.2u}}}I r},1p=q(o,t,a){4 b=d.2r(t||\'x\');15(4 p 1E o){p==\'v\'?b[p].3M=o[p]:b[p]=o[p]}I(a||J).34(b,(a||J).2m)},x=1p({3K:"3J",v:"1D:2k;z-3G:3F;1a:1l"}),13=1p({3K:"3J",v:"1D:2k;z-3G:3F;1a:1l;V:50%;1f:50%;"}),2e,2Z,1L,2U,as,1K={},3y=["1m.1n","6E.1n","6F.1n","6G.1n","6H.1n","6I.1n","6J.1n"],3w=d.1S(\'1B\');15(4 i=0,1e,1I;1e=3w[i++];){n(1I=1e.19.6P(/1I=(\\d)$/)){6Q}}n(1g.1m){1p({1s:Z.1v+\'/1t/3p.1t\',3o:\'3n\',2C:\'1i/1t\'},\'3k\',1x)}y{d.70(\'<3k 1s="\'+Z.1v+\'/1t/3p.1t" 3o="3n" 2C="1i/1t" /><a 1s="#" 3j="I $11.3h(17)" 3f="I $11.2x()" 77="$11.3d()" 2t="I $11.2d()"><2c 19="\'+Z.1v+\'/7c/\'+3y[(1I&&1I[1])||0]+\'" Y="7e" M="21" 1c="0" N="36"/></a>\')}$11={7i:x,7j:13,2i:q(b){4 c=1g.7l||b,t=c.7m||c.33,4G=13.4F?13.4F(t):!!(13.7q(t)&16),a=d.1h(\'36\');n(!4G&&t!=a){13.v.1a=\'1l\'}},3h:q(a){n(!17.a){17.a=a;1p({19:Z.1v+\'/7s.4B\',2X:\'2S-8\'},\'1B\',1x)}y{4 p=3u(17.a),4s=4p(),4r=2b();7z(x.v){1a="4q";V=(p.t+17.a.1z+x.1z>4s.h+4r.t?p.t-x.1z-(2Y?1:8):p.t+17.a.1z+1)+\'1M\';1f=p.l+\'1M\'}};I 1j},2x:q(){2e=4m(q(){x.v.1a=\'1l\'},29)},3d:q(){2D(2e)},2d:q(){x.v.1a=\'1l\';n(!17.1B){17.1B=1p({19:Z.1v+\'/7G.4B\',2X:\'2S-8\'},\'1B\',1x);J.v.1D=\'7H\'}y{4 a=2b();13.v.1a="4q";13.v.1d=(-13.1z/2+a.t)+"1M "+(-13.4e/2+a.l)+"1M";1L=d.1h(\'7L\'),2U=1L.2n(4a),as=2U.1S(\'7O\');15(4 i=0,1e;1e=as[i++];){1K[1e.49]=1e.2u}}I 1j},7Q:q(o){2D(2Z);2Z=4m(q(){4 s=o.49.2l(/^\\s+|\\s+$/,\'\'),2R=d.7T();15(4 p 1E 1K){45("4 f = /"+(s||\'.\')+"/7V.1r(p)");!!1K[p].2n&&(f&&2R.2G(1K[p].2n(4a)))}1L.43=\'\';1L.2G(2R)},29)},7Y:q(){13.v.1a=\'1l\'},2F:q(A){1p({19:A,2X:"2S-8"},"1B",1x)},3Y:q(F,O){n(F){F=3V(F)=="q"?F:45(F);F(O)}}};x.3j=q(){2D(2e)};x.3f=q(){$11.2x()};2Y?d.85("2t",$11.2i):d.86("87",$11.2i,1j);1g.1m&&$11.2d()})();q 88(a){4 b=3U(),1o=3T();2q{4 c=2M||{}}2j(e){4 c={}};4 d=8f,1F=Z.4o[a]||{},U=8i(c.12||H.2A),W="?3N="+a,G="&12="+d(U),T="&14="+d(c.14||H.14),S=c.1H?"&1H="+d(c.1H):"",F=Z.2E?"&2E="+1k(Z.2E):"",E=c.8t?"&8u=1":"",K=(c.1Y&&c.1Y[a])?"&1Y="+c.1Y[a]:"",P=c.1o?"&1o="+d(c.1o):"",R=(c.27&&c.27[a])?"&27="+c.27[a]:"",Q=(c.2N&&c.2N[\'1V\'])?c.2N[\'1V\']:2B,A=\'2g://s.1m.7/\',X=(1F.1J&&1F.12)?"&8E="+d(1F.1J)+"&8F="+d(1F.12):"",B=A+W+G+T+F+E+K+P+R+S+X;n(a==\'3r\'||a==\'3q\'||a==\'3l\'||a==\'1G\'){$11.2F(B);n(a==\'3r\'){3i()}y n(a==\'3q\'){3g()}y n(a==\'1G\'){3e=c.14||H.14;3c=c.1H?c.1H:(b?b:"");3b=G.2l(\'&12=\',\'\');39=3e+3c;38=37(39,8S);35(d(38+\'...\'),3b)}y{1g.3l()}}y{1g.2F(B,\'\')}$11.3Y(Q,{2C:\'1V\',8U:{8V:a,12:U}});I 1j}q 3g(){2q{4 d=2M||{}}2j(e){4 d={}};4 a=d.14||H.14;4 b=d.12||8W.2A.1s;4 c=1g.8X;n(c&&!!c.4H){c.4H(a,b,"")}y n(H.4x){1g.8Z.90(b,a)}y{1W(\'请按 4u + D 为你的浏览器添加书签!\')}}q 3i(){2q{4 d=2M||{}}2j(e){4 d={}};4 a=d.12||17.2A.1s;4 b=d.14||H.14;4 c=b+" "+a;4 f=1C.1q.4t();4 g=f.2p(\'4k\')!=-1&&4k.96();4 h=(f.2p(\'1N\')!=-1&&!g)&&f.98(f.2p(\'1N\')+5,3);n(h){9a.9b(\'9c\',c);1W("复制成功,请粘贴到你的1y/1X上推荐给你的好友!")}y n(9d(\'你使用的是非4f核心浏览器,请按下 4u+C 复制代码到剪贴板\',c)){1W(\'复制成功,请粘贴到你的1y/1X上推荐给你的好友!\')}y{1W(\'目前只支持4f,请复制地址栏9f,推荐给你的1y/1X好友!\')}}q 3T(){4 a=H.1S(\'2c\'),1o=\'\',2s=\'\',1Z=9i 9j();15(i=0;i<a.20;i++){4 b=1k(a.2y(i).4e),42=1k(a.2y(i).1z);n(b>9n&&42>29){1o+=2s+a.2y(i).19;2s=\',\'}}1Z=1o.9o(\',\');4 c=1k(4z.9p()*1Z.20);I 1Z[c]}q 3U(){4 a=\'\';4 b=H.1S("9q");4 c=b.20;n(/1N/i.1r(1C.1q)){15(i=0;i<c;i++){n(b[i].1J==\'22\'){a=b[i].23}}n(a==\'\'){15(k 1E b){n(k==\'22\'){a=b[k].23}}}n(/1N 6/i.1r(1C.1q)){a=\'\'}}y{15(k 1E b){n(/9v/i.1r(1C.1q)){n(3V(b[k].1J)!=\'9w\'){n(b[k].1J==\'22\'){a=b[k].23}}}y{n(k==\'22\'){a=b[k].23}}}}a=a.2l(/\\s/g,\'\');I a}q 9x(o,t,a){4 d=H,J=d.2f;4 b=d.2r(t||"x");15(4 p 1E o){p=="v"?(b[p].3M=o[p]):(b[p]=o[p])}4 j=d.1h(o.N);n(j){$("#"+o.N).9z();I(a||J).34(b,(a||J).2m)}y{I(a||J).34(b,(a||J).2m)}}q 37(a,b){4 c=0;4 s="";15(4 i=0;i<a.20;i++){n(a.9A(i)>9B){c+=2}y{c++}s+=a.9C(i);n(c>=b){I s}}I s}q 35(a,b){3R(\'\',b,a);I 1j}q 3R(a,b,c){4 d,24,25,26,1O,Y,M,28,1O;n(e=H.1h(\'1P\')){e=H.1h(\'1P\')}y{4 e=H.2r("x");2J=/1N|9L 6/.1r(1C.1q);n(!2J){e.v.3s="9N"}e.v.1D="2k";n(2J){e.v.1f=\'9O\';e.v.V=1k(H.4C.2a)+9P+\'1M\';e.v.3s="9Q"}e.N=\'1P\'}n(a){d=a;24=\'在微信上关注我们\';25=\'打开微信,点击底部的“发现”,使用 “扫一扫” 即可关注我们。\';26=\'<2c 19="\'+d+\'" v="1d-V:9R;" Y="3m" 3a="二维码加载失败" M="3m" N="4A">\';Y=\'Y:4y;\';M=\'M:4y;\';28=\'M:9W;\';1O=\'1d: -9X 0 0 -2K;\'}y{d=Z.2H+\'?3N=1G&12=\'+b+\'&14=\'+c+\'&9Z=1j\';24=\'分享到微信朋友圈\';25=\'打开微信,点击底部的“发现”,使用 “扫一扫” 即可将网页分享到我的朋友圈。 <a 1s="\'+d+\'" 33="a0">如何使用?</a>\';26=\'<2c 19="\'+Z.2H+\'/a1.a2?12=\'+b+\'" 3a="二维码加载失败" v="1d-V:4n;" Y="4j" M="4j" N="4A">\';Y=\'Y:4g;\';M=\'M:4g;\';28=\'M:a6;\';1O=\'1d: -2K 0 0 -2K;\'}e.43=\'<x N="4b" v="2L-a9: 1Q-2O;2L-2Q: #2T;1c: 1R 2V 3P(0, 0, 0, 0.3);  1c-3O: 1w 1w 1w 1w;  2O-2W: 0 ak al 3P(0, 0, 0, 0.3); 1f: 50%; \'+1O+\'2v: 3D; 1D: an; V: 50%; \'+Y+M+\' 2v:3D;" 1T="4b"><x 1T="3z" N="3z" v="1c-aq: 1R 2V #ar; 1Q: at 4n;"><a v="1i-au:1l;  1d-V: av; 2Q: #aw; ax: 3v;  1A-30: 48;  1A-44: aD; aE:aF;41-M: 48; aH: 0.2; 1i-2W: 0 1R 0 #2T;"1T="3Z" N="3Z" 2t="3X()"33="aK">×</a><3I N="aM"v=" 41-M: aN; 1d: 0; 1A-44:aO; 1A-aP:"微软雅黑";">\'+24+\'</3I></x><x 1T="3B"N="3B"v="1i-2o:2d;\'+28+\'"><p>\'+26+\'</p></x><x 1T="3Q" N="3Q"v=" 2L-2Q: #aT;  1c-3O: 0 0 1w 1w; 1c-V: 1R 2V #aU; 2O-2W: 0 1R 0 #2T aV; M:29%;1Q:0 aW;1Q-V:aX;1i-2o: 3v; 1A-30:47;"><x N="aZ"v="1i-2o:1f;1d:0; 1Q:0;1A-30:47;">\'+25+\'</x>  </x></x>\';H.2f.2G(e);3L=H.1h("1P")}q 3X(){32=H.1h(\'1P\');H.2f.b2(32);32=b3=3L=b4=2B}',62,687,'||||var|||com||||||||||||||||if|||function|||||style||div|else|||||||||document|return|db||www|height|id||||||||top|||width|JIATHIS_CONFIGS||CKE|url|div1|title|for||this|cn|src|display|dd|border|margin|ci|left|window|getElementById|text|false|parseInt|none|jiathis|gif|pic|creElm|userAgent|test|href|css|add|codehost|6px|head|QQ|offsetHeight|font|script|navigator|position|in|cu|weixin|summary|Bn|name|texts|list|px|msie|mt|jiathis_weixin_share|padding|1px|getElementsByTagName|class|qq|share|alert|MSN|appkey|picArr|length||description|content|wt|ft|innerhtml|ralateuid|bh|100|scrollTop|getS|img|center|timer|body|http|baidu|disappear|catch|absolute|replace|firstChild|cloneNode|align|indexOf|try|createElement|con|onclick|parentNode|overflow|bt|out|item|getPropertyValue|location|null|type|clearTimeout|uid|open|appendChild|shost|sTL|isIe6|200px|background|jiathis_config|evt|box|scrollLeft|color|frag|utf|FFFFFF|clist|solid|shadow|charset|ie|inputTimer|size|isStrict|_oDlgEl|target|insertBefore|jiathis_sharewx|jiathis_a|jiathis_SetString|AS|AT|alt|WU|WS|move|WT|onmouseout|jiathis_addBookmark|over|jiathis_copyUrl|onmouseover|link|print|129|stylesheet|rel|jiathis_share|fav|copy|zIndex|mail|getP|right|scripts|youdao|tagImgs|jiathis_modal_header|my|jiathis_modal_body|tumblr|hidden|douban|100000|index|instapaper|h3|jiathis_style|className|_oMaskEl|cssText|webid|radius|rgba|jiathis_modal_footer|jiathis_popup|facebook|jiathis_get_pic|jiathis_get_des|typeof|shuqian|jiathis_cancel|fireEvent|jiathis_weixin_close|while|line|imgH|innerHTML|weight|eval|getBoundingClientRect|12px|20px|value|true|jiathis_weixin_modal|isGecko|ly|offsetWidth|IE|360px|hi|digg|220|opera|ru|setTimeout|15px|custom|getWH|block|tl|wh|toLowerCase|Ctrl|hexun|ua|all|300px|Math|jiathis_follow_img|js|documentElement|google|189|contains|contain|addPanel|delicious|fm|pinterest|ping|Plaxo|plaxo|jt_delicious|Delicious|Ping|jt_wong|Mister|Wong|misterwong|jt_stumbleupon|Stumbleupon|stumbleupon|jt_plurk|Plurk||plurk|jt_funp|Funp|funp|jt_myshare|Myshare|myshare|jt_pingfm|phonefavs|Phonefavs|jt_phonefavs|compatMode|CSS1Compat|netvibes|Netvibes|jt_netvibes|netlog|NetLog|max|jt_netlog|mixx|Mixx|jt_mixx|myspace|Myspace|jt_myspace|friendfeed|FriendFeed|jt_friendfeed|diigo|Diigo|clientHeight|clientWidth|jt_diigo|Mail|jt_mailru|Digg|jt_digg|bit|bitly|Bit|gecko|jt_bitly|w3cyz|W3c|jt_w3c|yhdy|jt_printfriendly|pdfzxzh|Pdf|clientTop|jt_pdfonline|clientLeft|yijee|yjw|defaultView|jt_yijee|offsetTop|offsetLeft|dig24|getComputedStyle|dkw|jt_dig24|ctw|jt_chouti|jjdq|jt_99earth|cyzone|cyb|visible|offsetParent|jt_cyzone|wkw|jt_waakee|wo|wfx|iwo|WO|jt_iwo|eastmoney|cm|jt_caimi|getpocket|pocket|Pocket|jt_pocket|Instapaper|jt_instapaper|reddit|Reddit|jt_reddit|Tumblr|jt_tumblr|flwb|jt_jcrb|163|yxjh|jt_dream163|hxwb|jt_thexun|leihou|jiathis1|jiathis2|jiathis3|jiathis4|jiathis5|jiathis6|lhw|jt_leihou|poco|pocow|Poco|match|break|jt_poco|ganniu|gnw|jt_ganniu|mogujie|mgj|jt_mogujie|mls|jt_meilishuo|write|mop|tk|mptk|jt_mop|tuita|tt|onmousemove|jt_tuita|ggfy|jt_translate|xhwb|images|jt_txinhua|125|people|rmwb|jt_tpeople|pop|centerpop|club|event|srcElement|yyq|jt_189cn|189yx|compareDocumentPosition|jt_189mail|ckepop|139yx|139|jt_139mail|bookmark|hx|jt_hexun|with|xueqi|xqw|jt_xqw|hotmailyx|Hotmail|jt_hotmail|ckecenterpop|static|apps|bdkj|jt_hi|jiathis_sharelist|ylwb|jt_tyaolan|input|duitang|choose|dt|jt_duitang|createDocumentFragment|jt_plaxo|ig|Pinterest|jt_pinterest|centerClose|msn|jt_msn|qqsq|jt_qq|ydsq|jt_youdao|attachEvent|addEventListener|click|jiathis_sendto|ggbuzz|Buzz|jt_buzz|gg|jt_google|db9d|encodeURIComponent|jt_douban9dian|mingdao|String|md|jt_mingdao|fanfou|ff|jt_fanfou|ifeng|fhwb|jt_tifeng|qbj|jt_qingbiji|data_track_clickback|jtss|tieba|bdtb|jt_tieba|tianya|tysq|jt_tianya|note|ydybj|jt_ydnote|acn|acu|gmailyx|Gmail|jt_gmail|cang|bdsc|jt_baidu|mkjs|jt_sdonote|pengyou|pyw|jt_xiaoyou|1688|110|albb|data|service|parent|sidebar|jt_alibaba|external|AddFavorite|plus|googlej|Google|jt_googleplus|txwb|version|jt_tqq|substr|huaban|clipboardData|setData|Text|prompt|hbw|URL|jt_huaban|im|new|Array|yixin|yx|jt_yixin|300|split|random|meta|cnxh|jt_ujian|yjfx|jt_ishare|chrome|undefined|jiathis_creElm|Facebook|remove|charCodeAt|128|charAt|jt_fb|co|twitter|Twitter|jt_twitter|jt_douban|10086|feixin|MSIE|space|101120000000|550px|200|1000000|25px|fx|jt_feixin|linkedin|jt_linkedin|181px|100px|evernote|isexit|_blank|qrcode|php|jt_evernote|kaixin001|kxw|251px|jt_kaixin001|renren|clip|rrw|jt_renren|yj|jt_email|dy|jt_print|scj|jt_fav|fzwz|jt_copy|3px|7px|qzone|fixed|sns|qqkj|bottom|EEEEEE||9px|decoration|2px|000000|float|jt_qzone|connect|qqhl|cqq|jt_cqq|bold|cursor|pointer|weibo|opacity|xlwb|jt_tsina|_self|wx|jiathis_weixin_h3|30px|normal|family|jt_weixin|servicelist|sc|F5F5F5|DDDDDD|inset|10px|11px|code|jiathis_weixin_tip|v3|webhost|removeChild|_oDivEl|_oErweimaMaskEl'.split('|'),0,{}))

代码很长,不过我们不用太做深入的研究,只看最前面的的eval就明白大致原理了,eval是执行javascript代码的意思。

根据我么的猜测,eval函数里面一定就是踏出分享的弹窗代码,其中定义了一些样式和语言等。

这就给我们开发浏览器功能提供了一个思路,我们可以通过引入第三方的js,然后执行它,来实现自己的扩展功能。