Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CustomVariables are not tracked when using the piwik.php 'no footprint' proxy script #4831

Closed
anonymous-matomo-user opened this issue Mar 8, 2014 · 5 comments
Labels
Bug For errors / faults / flaws / inconsistencies etc. worksforme The issue cannot be reproduced and things work as intended.

Comments

@anonymous-matomo-user
Copy link

There is a bug in the track if you are using the proxy script. Due to the proxy script the quotes are escaped in the json-string. So it is not possible for the tracker to get the json-string and log the CustomVariables. Here ist a hotfix:

file: core/Tracker/Request.php
line: 350

Insert:

#!php
        if (is_array($this->params) && array_key_exists($parameter, $this->params) && !empty($this->params[$parameter])) $this->params[$parameter]=stripslashes($this->params[$parameter]);

I don't know if it is possible to dected the Request comes from the javascript or the proxyscript so you can modify the if-query...

Regards,
easy.

@mattab
Copy link
Member

mattab commented Mar 9, 2014

Thanks for the report! we'll try reproduce and fix it

@mattab
Copy link
Member

mattab commented May 14, 2014

In dd74312: Refs #4831 I could not reproduce this bug. So maybe it is because Magic quotes runtime was on on your server running the proxy script?

could you please try to apply this patch to your piwik.php on proxy and tell me if you still have the issue?

@mattab
Copy link
Member

mattab commented May 14, 2014

See related FAQ Setup Piwik without footprint

@anonymous-matomo-user
Copy link
Author

Hi,

sorry for the Delay but that does not help.

Still get the quotes escaped. Example of a print_r($this->params):

    [cvar] => {\"3\":[\"_pks\",\"203.985.KCMY\"],\"4\":[\"_pkn\",\"\"],\"5\":[\"_pkc\",\"Brother DCP J315 W\"]}
    [_cvar] => {\"1\":[\"NLC-20140523\",\"o1\"]}

Have to insert my line (see above) every time after an update.

Regards,
easy.

@anonymous-matomo-user anonymous-matomo-user added this to the 2.5.0 - Piwik 2.5.0 milestone Jul 8, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
…ecause Magic quotes runtime was on on your server running the proxy script?

could you please try to apply this patch to your piwik.php on proxy and tell me if you still have the issue?
@mattab
Copy link
Member

mattab commented Dec 19, 2014

Cant' reproduce, please reopen if you still have issue

@mattab mattab closed this as completed Dec 19, 2014
@mattab mattab added the worksforme The issue cannot be reproduced and things work as intended. label Dec 19, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. worksforme The issue cannot be reproduced and things work as intended.
Projects
None yet
Development

No branches or pull requests

2 participants