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

Page urls appearing "flat" in hierachical view #10858

Closed
phoob opened this issue Nov 13, 2016 · 5 comments
Closed

Page urls appearing "flat" in hierachical view #10858

phoob opened this issue Nov 13, 2016 · 5 comments
Labels
answered For when a question was asked and we referred to forum or answered it. Bug For errors / faults / flaws / inconsistencies etc. Waiting for user feedback Indicates the Matomo team is waiting for feedback from the author or other users.

Comments

@phoob
Copy link
Contributor

phoob commented Nov 13, 2016

Using Piwik 2.17.0 (PHP 7.0.8-0ubuntu0.16.04.3), I get some odd behavior for the Actions reports where the tables are based on page urls. Some urls are displayed twice: once in hierarchies and once flat. They have different counts for page views etc. See attached screen shot. I have no idea where to start explaining this.. but I can't seem to find any similar issue here.

screenshot

@mattab
Copy link
Member

mattab commented Dec 6, 2016

Thanks for the report @phoob - it does look like a bug and we haven't heard about this otherwise.

Does anyone else experience this issue?

@mattab mattab added Bug For errors / faults / flaws / inconsistencies etc. Waiting for user feedback Indicates the Matomo team is waiting for feedback from the author or other users. labels Dec 6, 2016
@mattab mattab added this to the 3.0.0 milestone Dec 6, 2016
@phoob
Copy link
Contributor Author

phoob commented Dec 10, 2016

Seems it might be related to the fact that I used jQuery Waypoints to track events (when user scrolled to 50%, 75% and 100% of pages). The symptoms came and went away at about (but not exactly) the same time I tried that... this was the code that I used:

$(document).ready(function() {
  window.trackScrolling();
});

window.trackScrolling = function(){
  var waypoints = [0.75,1];
  waypoints.forEach(function(wp,i){
    var dh = $(document).height();
    var wh = $(window).height();
    var currentUrl = window.location.href.split('?')[0].replace(/\/?$/, '/'); // <-- could that f**k s**t up?
    waypoints[i] = new Waypoint({
      element: document.body,
      handler: function(dir){
        _paq.push(['trackEvent', 'Scroll', wp*100 + '%', currentUrl ]);
        this.destroy();
      },
      offset: '-' + ((dh*wp)-wh)
    });
  });
};

@tsteur
Copy link
Member

tsteur commented Dec 11, 2016

Maybe some URLs are sent URL encoded and some not. Try _paq.push(['trackEvent', 'Scroll', wp*100 + '%', decodeURIComponent(currentUrl) ]);

@mattab
Copy link
Member

mattab commented Dec 15, 2016

Btw there's also this tool for tracking scrolls down the page in piwik http://rodi.sk/misc/piwik-scroll-depth/

@mattab
Copy link
Member

mattab commented Jun 19, 2017

Cannot reproduce yet

@mattab mattab closed this as completed Jun 19, 2017
@mattab mattab added the answered For when a question was asked and we referred to forum or answered it. label Jun 19, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
answered For when a question was asked and we referred to forum or answered it. Bug For errors / faults / flaws / inconsistencies etc. Waiting for user feedback Indicates the Matomo team is waiting for feedback from the author or other users.
Projects
None yet
Development

No branches or pull requests

3 participants