|
. @2 E: p2 W4 _" T" j# I& y5 k7 B% v) p
- <html xmlns="http://www.w3.org/1999/xhtml">; a1 Q* Z; i: b
- <head>
4 ^& M+ S5 i" S - <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />( A( U5 O, }1 U
- <title> Afilter Tracker Google 广告点击追踪演示</title>5 G! |, v+ g% b% T" y
- <script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
" F3 k" n! }% j; i0 \3 l$ p1 t - <script type="text/javascript">
) ^. L- q7 \% b, i& r4 p
, _# k. B" H2 F: h" u' c" O+ R$ Z- var isOverGoogleAd = false;' E+ p8 Z2 l" c0 V/ G6 p7 T9 U& _- X
- var ad = /adsbygoogle/;% L5 f( p* q4 }" L7 i
- # d' I+ s+ _% d! p# w: C1 k
- $(document).ready(function()' w2 v- U/ t7 p0 N2 i( R% r% R: |
- {
* c+ i- f. ~) L- w - $('ins').on('mouseover', function () {, E2 ]/ l* O1 r* W5 _
- if(ad.test($(this).attr('class'))){$ y9 O4 C; m$ Y* s* g
- isOverGoogleAd = true;3 K0 Q+ n% |: @4 B4 D! p
- }3 k2 K: m1 I. y
- });
" Q" a u* @4 U4 ? - $('ins').on('mouseout', function () { h$ e* Q2 `& j6 D+ ]+ d5 Q
- if(ad.test($(this).attr('class'))){# W$ P- j: @: J& I
- isOverGoogleAd = false;0 B( X+ R% p u' D3 X
- }
3 r n* h& J: H - });! e4 x- B; ^: a$ \, N
- });5 Q1 w* N2 B6 |4 V: r0 l" P
# Y# u3 o* y3 Z7 L& B" y- $(window).blur(function(e){
( \4 t: S6 i2 A7 h/ d' a - if(isOverGoogleAd){
1 Z ~3 }, T5 a) O8 [/ e% x6 A; ` - //检测到点击。( h& {& T# D: g5 @' d
- }
! a! I7 Y8 s7 z+ D) s2 D - });
7 M/ ?: p+ r2 r9 Y, b" x - </script>
/ q u6 r! c" H1 P0 |5 J" O- E5 e' ? - </head>
/ ]8 } v: M) Q" _ - <body>
, K2 c1 A# }( K( A7 w2 l3 L
) {% M1 A% |4 L$ a3 S0 @- <script async src='//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js'></script>1 ]( |/ ]5 W% L. g, C
- <!-- qym -->9 @' b5 L9 i# }; k+ y& d
- <ins class='adsbygoogle'' i, M5 \! p' }4 G! z2 M
- style='display:inline-block;width:970px;height:90px'
* ^" H+ l; r% H, Y) C6 ` - data-ad-client='ca-pub-111111111111111'4 G+ |" \7 v: c# `
- data-ad-slot='1111111111'></ins>; M' W0 V( ~- C$ z3 S
- <script>. k" }8 V0 s$ l3 G) c: D! e4 e- G% g3 y
- (adsbygoogle = window.adsbygoogle || []).push({});! z% L, I: q+ I+ U3 o. q
- </script>
- |! Z, q3 M/ `
0 }4 z5 e$ ~% Z- </body>
% V# k" D8 l1 c5 i. r8 L N - </html>
复制代码
( Q F- Z5 B0 t, u4 v$ P& Y" Y# F. e/ X
Google Adsense 广告点击追踪的代码,亲测有效。
, @7 O% [2 ~! w, t" L: Y _8 Y3 L) Q- k6 s7 ?9 R
配合点击追踪 对于那些买流量做adsense的 很有帮助。
: ~5 X1 K% K, m+ v u& [8 l" }9 X" r. V1 N4 z' j) D2 }
|
评分
-
查看全部评分
|