@MERamadan opened this Issue on May 1st 2019

When posting a download action with query parameter Downalod (capital D), it is tracked as a page view instead of download action.

All query parameter keys should be case insensitive to avoid similar issues.

Generate Steps:

Related Issue (Matomo .Net Client):

@MERamadan commented on May 1st 2019

Proposed Solution:
File: matomo\core\Tracker\Request.php
Added the following line to lower incoming request query keys before set this->params
$params=array_change_key_case($params, CASE_LOWER);

Complete Code:

public function __construct($params, $tokenAuth = false)
        if (!is_array($params)) {
            $params = array();
    $params=array_change_key_case($params, CASE_LOWER);
       /**....same old code....**/
@tsteur commented on May 1st 2019 Member

Hi there, the proposed solution could break a lot of things. In general, the last time this was suggested it was closed because urls are usually not case insensitive see https://github.com/matomo-org/matomo/issues/10534

You would implement this in the client you use. For example if you use JS, and want pageviews to be case insensitive, you could do something like _paq.push(['setCustomUrl', location.href.toLowerCase()]). Similar things probably work in the dot net tracker.

This Issue was closed on May 1st 2019
Powered by GitHub Issue Mirror