Resource icon

Track Usergroups in Google Analytics

Hi @DBA I'm coming back to this now. Why is there a "1" after the </xen:if>?

And why do we need it to look like:
'Registered-2',

And now just "Registered"?
 
Last edited:
DBA updated Track Usergroups in Google Analytics with a new update entry:

Updated to work with Google Universal Analytics

Finally updated it to work with Universal.

In Google Analytics go to the Admin tab and select Custom Definitions under your Property. Add your new Custom Dimension's, I only did a Logged-In and Guest.

View attachment 139661

Add the new code to the google_analytics template on your website like this (be sure that your dimension numbers match with the code on Google Analytics):
PHP:
    ga('create', '{$xenOptions.googleAnalyticsWebPropertyId}', 'auto');
<xen:if is="{$visitor.user_id}">...

Read the rest of this update entry...
 
@DBA how long after I change the Google_Analytics template, add the code, and the custom Dimensions in GA will it start to track the different user Groups? Hours, days, weeks?
 
@DBA how long after I change the Google_Analytics template, add the code, and the custom Dimensions in GA will it start to track the different user Groups? Hours, days, weeks?
It should start tracking right away however I think it took a few hours before it showed up in the same day report.
 
I keep hoping that @DBA or another master-coder will come up with a great way to segment / track guests, members, and other user-groups in Google Analytics.
 
@DBA
I know this is unmaintained/unsupported, was wondering if you've figured out a way to add this to DigitalPoint's Better Analytics? Been messing with the code and it's just making me dizzy lol
 
Top Bottom