Most blogs that I read/visit regularly have only a snippet or extract about the post on the homepage or its series of archives. This I feel is a great idea because it allows me to read a sentence or two before I decide to progress. However, what I have always wondered is what the click through rate is for my posts - are people compelled enough to read more?
Recently Google Analytics allows you to track events (such as clicks on objects on a web page) and I will show you how you can do this for your own Wordpress blog.
Step 1: Have the Latest GA code
In order for the Event Tracking code to log the events correctly, you need to use the ga.js code and not the legacy. Please check before going ahead.
Find the Relevant Wordpress Theme Files
Now we have to find out where in the Wordpress theme the link is generated that allows people to click through to the full post. But here is the catch - there is more than one way to go through to the post from these index.php and/or archive.php - the headline and the read more link. So we have 2 events to track:
- Visitors Clicking the Headline
- Visitors Clicking the ‘read more’ link
The Code to Add to the Anchor Tag
Ok, so now you have found the location where the anchor tag is generated, its time to add our javascript code. It will follow this format:
onClick=”pageTracker._trackEvent(’post-click-thrus’, ‘going-to-read’, ‘Identifier’);“>Play
Lets break this down parameter by parameter:
- Category: This basically groups all our events under one kind of category - in this case post-click-thrus
- Event: What this does is register the type of event that is performed under the category. In this case we can assume that if a visitor clicks on the ‘read more’ link or blog title they are going through with the parameter going-to-read
- Identifier: This will now tell us how we can identify this event, whether it was a ‘read more’ click or a headline click. In this case we did read-more-link, we will need to create a separate event tracking for the headline, and I would use headline-link to identify that.
- Source: Google Event Tracking Guide
Play the Waiting Game & Checking the Data
So where can we see the report? Well that is the easiest part. Google has put it in a very handy place, under the umbrella of the content reports. If you Content Report, depending on your setup it will be toward the end of the reports list, under the heading Event Tracking. The rest of the report is fairly straight forward with the data it provides. At a later date, we will talk about a quick and easy way to extract data from large analytics report.
Leave your comments as to any fancy implementations of event tracking you have done on your website/blog and we can add it to the list.
{ 2 trackbacks }
{ 0 comments… add one now }