內容簡介
使用 jQuery 將 Google Analytics 追蹤代碼新增到所有頁面的電話鏈接和電子郵件鏈接上。
添加並啟用外掛
外掛將自動運作!
此外掛是開源的,程式碼在這裡: https://www.github.com/harrymt/simple-tel-tracking
郵件和電話鏈接的 href=X 也會被傳送到 Google Analytics。
例如,對於這兩個鏈接:
<a href="mailto:[email protected]">[email protected]</a>
<a href="tel:+123456789">Bristol 123456789</a>
Google 會報告:
ga('send', 'event','Mailto Tracking: [email protected]','Click/Touch');
ga('send', 'event','Phone Call Tracking: 123456789','Click/Touch');
外掛標籤
開發者團隊
原文外掛簡介
Uses jQuery to add Google Analytics tracking code to all tel links and mailto links on all pages.
Add and enable plugin
It just works!
The plugin is open-source, the code is here: https://www.github.com/harrymt/simple-tel-tracking
The href=X of the mail and tel link will also be sent to Google Analytics.
e.g. for these two links
[email protected]
Bristol 123456789
Google will report:
ga('send', 'event','Mailto Tracking: [email protected]','Click/Touch');
ga('send', 'event','Phone Call Tracking: 123456789','Click/Touch');
