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

Possibility to add tracking for form analytics #3

Open
mpisters opened this issue Aug 9, 2018 · 2 comments
Open

Possibility to add tracking for form analytics #3

mpisters opened this issue Aug 9, 2018 · 2 comments
Assignees
Labels
enhancement New feature or request
Projects

Comments

@mpisters
Copy link

mpisters commented Aug 9, 2018

Would it be possible to add a function to do form analytics with matomo. I have read the guide and I don't think it would be too hard to implement.
https://developer.matomo.org/guides/spa-tracking

It should include this function:
_paq.push(['FormAnalytics::scanForForms', documentOrElement]);

@Arnaud73
Copy link
Owner

Arnaud73 commented Aug 9, 2018

I'll look into it!

@Arnaud73 Arnaud73 added the enhancement New feature or request label Aug 9, 2018
@Arnaud73 Arnaud73 self-assigned this Aug 9, 2018
@mpisters
Copy link
Author

mpisters commented Aug 9, 2018

I found out that for manually tracking one form that you should use:

_paq.push(['FormAnalytics::trackForm', documentOrElement]);

and to track a submit:
_paq.push(['FormAnalytics::trackFormSubmit', document.getElementById('login')])

Found in doc: https://developer.matomo.org/guides/form-analytics/faq

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Development

No branches or pull requests

2 participants