|
& R8 s& J6 o8 c
- <html xmlns="http://www.w3.org/1999/xhtml">
4 t1 g2 ~" D) l! v5 | U - <head>
7 u1 q) r' j& I - <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />9 D/ s& U% ^; d. a, J1 H u
- <title> Afilter Tracker Google 广告点击追踪演示</title>
1 }2 J j$ O3 P% k* c - <script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
1 M5 ~0 A% O5 k: L' J/ s+ Z - <script type="text/javascript"> F8 J; y9 W( s6 j* W$ e5 B
- U& \2 ^7 ?1 ^7 z$ `/ R4 ]- var isOverGoogleAd = false;
7 B" l0 V7 w2 B - var ad = /adsbygoogle/;
! x3 R) d/ e+ @$ }3 G3 |* [% i+ J0 t' m [
0 G2 B. Y$ P [) ~$ w0 R- $(document).ready(function()
# u6 {1 {) c) ~8 J r! g - {5 w6 s0 x/ g2 [5 D P+ p
- $('ins').on('mouseover', function () {
" ?* j9 S* N$ I/ |: q1 o - if(ad.test($(this).attr('class'))){
) e7 _( u$ J, s - isOverGoogleAd = true;: n! ?6 x* g- s4 o# U6 D
- }$ j; M' M9 s3 u9 G, i* W
- });
$ q/ Y! I! ?# O: e/ k% E) J" W - $('ins').on('mouseout', function () {
1 J2 h' K. D( o2 j" y4 m - if(ad.test($(this).attr('class'))){
; j9 S; F: M6 M - isOverGoogleAd = false;
7 S" J+ X" ~% f2 x6 ] - }
i4 u3 Q% c$ v$ @* V/ c - });
4 L" ]0 E: w9 R9 |6 L' y5 f" { - });
1 I) ^& @, _" S3 o& i- ~ - - I2 @& {9 D/ ]. `+ f
- $(window).blur(function(e){' Q9 v; l' d4 y! C
- if(isOverGoogleAd){9 k0 N% ?( Q. H
- //检测到点击。
) ]1 f; c5 e X C8 |. D - }
! i* Q" E" X. I: @ - });
; Q N. X0 A, _' S4 e1 Q, ]+ i1 u - </script> b4 d+ Z, P. C' s0 {/ A" L6 E6 {
- </head>! M" ^# B" w+ { n1 e5 V
- <body>
( y4 i& k# H0 O& v3 x - % G" K' @" M' h3 m9 @
- <script async src='//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js'></script> P1 i, L& Q. k" R
- <!-- qym -->
! r% L" f) W/ L0 M# X/ A - <ins class='adsbygoogle'
5 n! [+ h' }3 }; v3 X7 g2 w - style='display:inline-block;width:970px;height:90px'! u+ A9 N9 ]+ u+ l6 Z; P1 S
- data-ad-client='ca-pub-111111111111111'
4 c: e6 @4 C" d/ X - data-ad-slot='1111111111'></ins>; a/ [# i2 V5 a' J) ?/ X9 t9 {
- <script>
9 h+ p1 y2 a" u% j - (adsbygoogle = window.adsbygoogle || []).push({});/ f. H8 P$ T7 \( T5 V
- </script>
/ m0 f+ m# O2 ^* ^' t- I - ! H/ H" {0 \* `* F
- </body>- ]7 d5 e* ?0 V7 X
- </html>
复制代码 " @/ R, m# q6 a" B( s( e: i
0 q! m" B; H: Q( R' a2 C
Google Adsense 广告点击追踪的代码,亲测有效。
6 V* _0 p% i2 Z2 l" e. t6 [+ ?) U2 {" C" k' S7 a
配合点击追踪 对于那些买流量做adsense的 很有帮助。6 ~+ o2 }/ C4 J9 X0 k1 H/ k/ v& F
# |) }8 P7 i9 }
|
评分
-
查看全部评分
|