URL query parameter tracking issue

Hi everyone! I have a problem.

Currently, Piwik [edit: latest stable beta 2.15.1 B-8] is tracking following URLs as the same, but they are different (at least, I wish to track them as different):

tracked as ‘example.com’:

example.com
example.com?theme=value1
example.com?theme=value2

tracked as ‘example.com/something

example.com/something
example.com/something?theme=value1
example.com/something?theme=value2

What I need is to track all above URLs as separate ones, but for some reason Piwik is treating them the same (e.g. stripping the query param) in Page logs.

I have searched and could not find the solution to this issue. We have exclusion list in admin, but there is no specific inclusion list. Any solution to this?

Thanks!

Hi @darko
that’s surprising: piwik should track the page parameters by default. Only parameters piwik removes are Session ID param, and campaign tracking parameters. can you reproduce this on a new website in PIwik?

Hi matthieu,

I think I have located the problem, when user clicks on ?param=… CMS will do its magic (change theme) and redirect user to the same page it was before the click. Now, Piwik is embeded via header hook, so at the time page loads the URL is already stripped down from any parameters (to avoid loop). I really have no other explanation for this.

Yes, you are correct. It does work, indeed. When I enter a direct URL (copy/paste in URL bar) with above param, it is captured properly.

I will have to change few things in my theme switcher, in order to be able to capture the URL.

Thanks!

edit: Unfortunately, I need to remove the ?theme param, because of the redirect loop, but I have replaced it with new param to avoid this and still keep track record. Finally, I have created a tracking event.

RESOLVED