catalyst / moodle-tool_webanalytics

A Moodle admin tool adding Web Analytics to your Moodle site.
https://moodle.org/plugins/tool_webanalytics
7 stars 10 forks source link

Support "Clean URLs" and "Track User ID" in Google Tag Manager #15

Open fishfree opened 5 years ago

fishfree commented 5 years ago

Now, Google Universal Analytics supports "Clean URLs" and "Track User ID", but Google Tag Manager doesn't.

dmitriim commented 5 years ago

@fishfree hey! thanks for submitting the issue.

Could you please be more specific about how this would affect the plugin?

Cheers, Dmitrii

fishfree commented 5 years ago

@dmitriim On the type of Google Universal Analytics settings page, we can check "Clean URLs" and "Track User ID", gua

But on that of Google Tag Manager, we cannot. gtag

dmitriim commented 5 years ago

@fishfree that's correct. Is that feature available for Google Tag Manager? Do you have documentation to related API?

fishfree commented 5 years ago

@dmitriim I read this article and this, user id and clean urls should be pushed into the GTM dataLayer by moodle-tool_webanalytics firstly. Then we need configure in the GTM management console to extract the user id and clean urls into variables and then send them to a GA tag.

dmitriim commented 5 years ago

Thanks @fishfree Let's mark this issue as Enhancement. Feel free to submit a patch for review.