How to add tracking code only to some posts?

Posted in: Newsmag
Post count: 20

Hi,
my new advertiser wants to have few promotional articles on our site in form of our standard post. But they want me to insert specific tracking code (Gemius Direct Effect) on every single promotional article to check traffic for every article separately. How can I add this code only to some posts? Any ideas?

Thanx in advance

Post count: 6535

Hi

The theme dos not have an option to add a tracking code only for some specific posts. You could try a plugin with a similar functionality but I can’t make any recommendation in this regard as we didn’t tested any of these plugins with our theme and I can’t say hoe they will work.
Also you can try to modify the file corresponding with the post template used for the promotional posts and add the tracking code there. For example let’s say that you’re using post template 1 for these posts. In this case the file that must be edited is single_template_1.php You have to check where the tracking code must be added on the page. Usually should be added after in page’s header or in footer: http://screencast.com/t/BPiF5uuA8huShttp://screencast.com/t/IRtdqCzNt30
Ideally would be to choose a specific post template only for the promotional posts so the tracking code to apply only for these posts.

Hope this help.
Thanks!

Viewing 2 posts - 1 through 2 (of 2 total)
The forum ‘Newsmag’ is closed to new topics and replies.