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

Add possibility to retrive the number of tracked pageviews in JS tracker #11655

Merged
merged 3 commits into from May 1, 2017

Conversation

tsteur
Copy link
Member

@tsteur tsteur commented Apr 28, 2017

Useful to detect eg if a page view has been already tracked or not.

@tsteur tsteur added c: Platform For Matomo platform changes that aren't impacting any of our APIs but improve the core itself. Needs Review PRs that need a code review labels Apr 28, 2017
@tsteur tsteur added this to the 3.0.4 milestone Apr 28, 2017
CHANGELOG.md Outdated
@@ -10,6 +10,7 @@ The Product Changelog at **[piwik.org/changelog](http://piwik.org/changelog)** l
* A new event `Db.getActionReferenceColumnsByTable` has been added in case a plugin defines a custom log table which references data to the log_action table
* A new JavaScript tracker method `getPiwikUrl` has been added to retrieve the URL of where the Piwik instance is located
* A new JavaScript tracker method `getCurrentUrl` has been added to retrieve the current URL of the website.
* A new JavaScript tracker method `getNumTrackedPageViews` has been added to retrieve the number of tracked page views.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Won't that description be a bit confusing? Someone might think it makes it possible to retrieve the number of pageviews tracked within the visit. But actually it only returns the number of trackPageView calls done within the current loaded page.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point 👍

@tsteur
Copy link
Member Author

tsteur commented May 1, 2017

@sgiehl I updated PR

@sgiehl
Copy link
Member

sgiehl commented May 1, 2017

Haven't had time to check out the branch and test it. But code looks good and as tests are passing I guess it'd be fine to merge.

@tsteur
Copy link
Member Author

tsteur commented May 1, 2017

👍

@tsteur tsteur merged commit faac4ff into 3.x-dev May 1, 2017
@tsteur tsteur deleted the getnumtrackedpageviews branch May 1, 2017 20:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: Platform For Matomo platform changes that aren't impacting any of our APIs but improve the core itself. Needs Review PRs that need a code review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants