O'Reilly logo

Piwik Web Analytics Essentials by Stephan A. Miller

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Tracking orders and products purchased

In the very least, you need to know how well your products are selling, so we will begin with tracking our sales. This is the base metric of all of our e-commerce tracking data. Your shopping cart itself will give you data on sales, but most shopping carts don't have a way of correlating this with your visitor data the way Piwik can. We will learn the revenue of each product, how many we have sold, and how many unique purchases of that product we have had. If our e-commerce shop has categories, we can track which categories produce sales and which need a little work.

In order to do this, we need to tell Piwik that we made a sale right before we call trackPageView() . We do this with two steps:

  1. Add the item ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required