feat: smart visitor detection for GA/GTM #8
Reference in New Issue
Block a user
Delete Branch "feat/smart-visitor-detection"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
dataLayerbefore GTM/GA4 loadsvisitor_type(guest/logged_in),visitor_group(Joomla user group name),page_type(component.view)user_propertiesfor persistent session-scoped dimensionsFiles changed
src/index.php— PHP user detection + dataLayer push + GA4 user_propertiessrc/templateDetails.xml— Newgooglevisitordetectionfieldsrc/language/en-US/tpl_mokoonyx.ini— Label and description stringssrc/language/en-GB/tpl_mokoonyx.ini— Label and description stringsCHANGELOG.md— Unreleased entryREADME.md— Updated feature bulletdocs/ROADMAP.md— New Smart Visitor Detection section + param referenceTest plan
window.dataLayerin browser console — confirmmoko.visitor_detectevent withvisitor_type: "guest",visitor_group: "none"visitor_type: "logged_in"andvisitor_groupshows the correct group namegtag('set', 'user_properties', ...)is present in page source🤖 Generated with Claude Code