|
* t0 e: q/ z/ J: g- Z
- <html xmlns="http://www.w3.org/1999/xhtml">
3 I- a# }! m% r9 b" S - <head>
0 c/ P8 h" _3 A, u( E/ X/ J - <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
( I) Z. s# z& N( r/ _& T+ e+ U* p - <title> Afilter Tracker Google 广告点击追踪演示</title>0 r, W, b9 p6 f/ S
- <script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>- k0 ~7 W( a- u3 ^; `$ K
- <script type="text/javascript">' ^( z" F' ?% T
6 p( I# ^) s( W; m' c0 ]% |2 l& a- var isOverGoogleAd = false;
, n0 k- }6 ]+ H! _# h" \ - var ad = /adsbygoogle/;
' v) o% ], [. f) O
# w1 t7 Z1 M7 L u& i0 v- $(document).ready(function()* K$ J+ V: B' N
- {1 ~0 N) c7 D. [& ~/ Q! o. x
- $('ins').on('mouseover', function () {
: g' X5 a- |: ?. r - if(ad.test($(this).attr('class'))){& ^5 w% q$ | ?1 s, V
- isOverGoogleAd = true;# ~8 g, d; B4 ^1 D; ~( q
- }
/ }2 i) t- R% y% T- k6 q$ o( |" R6 P - });) _+ o# ?7 y: i
- $('ins').on('mouseout', function () {" `7 o+ p6 X+ c. c$ i) Y* n
- if(ad.test($(this).attr('class'))){
9 ~1 U" G5 ~! g% q, F8 t. {4 x B - isOverGoogleAd = false;
3 x I7 L. X8 t1 j P( G* b - }
$ \- x( Q" M% x) e1 d6 p - });6 m' ~+ l! [2 O' `
- });
: x, M1 O( }/ i
* g3 o* _5 M) V* U# S5 }- W- $(window).blur(function(e){! c" U6 Q2 Y; S: _ q
- if(isOverGoogleAd){
% E& N+ ?! v/ g - //检测到点击。& f: E" f$ S5 e- R3 e p+ k
- }
: q& W( P; D9 P/ L& O$ Z - });$ f9 h }6 g5 U* k x* }2 h
- </script>
% v7 T) b4 U: f8 E - </head>% |2 h8 r5 H# @; t, w8 x
- <body>
0 ?: {" m5 F+ r m) t - $ d8 y3 M8 k$ z, K* r5 @1 B! t9 Q
- <script async src='//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js'></script>
, {, P$ R# @2 s3 x0 d0 q/ b7 U - <!-- qym -->5 s- ]! v' L* ?6 ?5 h
- <ins class='adsbygoogle'
+ u! n6 p3 Y8 h' o - style='display:inline-block;width:970px;height:90px'
+ E. T$ l- a% Y8 R - data-ad-client='ca-pub-111111111111111'
0 X3 N5 d. e+ j% Z$ V* w! | - data-ad-slot='1111111111'></ins>
* y5 J: L1 ^: ~6 Q - <script>( V" M+ ?0 R; V- i- W$ Q/ a
- (adsbygoogle = window.adsbygoogle || []).push({});
4 n, i( k0 G; P - </script>
5 F# q: t3 a( V# [* X6 U+ C; Z
9 S9 w' j# b7 ^3 |" U& {- </body> ?% u) Q+ \6 _2 M: I
- </html>
复制代码 1 |! C: R1 H, n
6 I" I, c: S. B9 y% O
Google Adsense 广告点击追踪的代码,亲测有效。
# w* z2 D5 h$ U5 Q @5 T o: [" c s7 V! z9 E" z
配合点击追踪 对于那些买流量做adsense的 很有帮助。
4 h/ h7 r9 I& p( a: \* u; `. s) X; ?, g( C, S2 R2 h* N3 P
|
评分
-
查看全部评分
|