內容簡介
這是一個小巧的 WordPress 外掛,用於追踪網站主內容區域中鏈接的事件。安裝後,就可以忘記它了。
這些鏈接將顯示在 Analytics 網站的「事件」下,類別為「鏈接」,標籤為「PageID: CURRENT_PAGE_URI」,並且鏈接所追踪的 href 將成為它的值。
以下是在主要文章內容中正確格式的 URL 中添加的程式碼範例:
<a onclick="ga('send', 'event', 'Links', 'click', 'http://twitter.com/chris_dickow');" href="http://twitter.com/chris_dickow">@chris_dickow</a>
以上範例假設鏈接的 href 是:http://www.myurl.com/my_blog/my_link.html
外掛標籤
開發者團隊
原文外掛簡介
A tiny WordPress plugin to track events of link clicks in the main content area of the site. Install it and forget about it.
Links will show up under Events in the Analytics site, and will have a category of ‘Links’, a label of ‘PageID: CURRENT_PAGE_URI’, and the value of the href of the link being tracked.
Example of code added to properly formed URLs in main post content:
@chris_dickow
The above example assumes the href of the link is: http://www.myurl.com/my_blog/my_link.html
