Custom variable values in Actions.getPageUrl?

Hi there,

basically what I’m looking for is to see values of customvariable for Actions.getPageUrl, so I’d like to see how many of each values had visited …

e.g. here at demo site -

how do I add to display custom variables so I can see how many “Anonymous” vs “LoggedIn user” visited this page?

PS - I could segment this, I know, but let’s say you have 20 values per custom variable, so it’s bit unpractical

If you want to see custom variables for a given page (example: containing “index”), you would do

Thanks for pointing me the right direction, actually below is what I was looking for using CustomVariables.getCustomVariablesValuesFromNameId


One more question on this, when I run below for week instead of day it returns nothing, similar for range e.g. last4 … is it bug or it’s not possible track custom variables this way?

This works:

but the idsubtable is now (2)

Ok, I get it - each period has different idSubtables, so I need to first retrieve those and then filter, perfect.


Happy New Year! If you are still using Piwik and interested in the awesome new feature of “Creating a Custom Segment in Piwik and apply to reports in Real time!” we need YOUR help, with a little or big donation at:

This will allow to dynamically add or edit, a new set of rules for example “Show all visitors from USA and using Firefox and using Google”. This will be done via a simple to use interface. See screenshots and more info here:

We are crowd funding the future of Piwik and this feature in particular. With your help we can do it.