ActiveCampaign Forum

How to associate site tracking to Contact (After Instantiation)



For those who have the user’s email when your page loads, before loading the tracking script, see these:

These directions require providing the email during instantiation, before calling pgo('process');

What is the best way to provide a user’s email AFTER instantiation?

I have a web app which may eventually obtain an anonymous user’s email, but it does so well after the AC tracking script has started, and it may likely be the exit page (I.E., I can’t expect to be able to store the address in a cookie/storage/etc. to provide to AC’s tracking script on the next page load).

Thank you!

How to associate site tracking to Contact

I’d just use Google Tag Manager to fire a pageview event with the AC tracking script when an email address becomes known (e.g. after login). So fire the same AC script but then with “pgo(‘setEmail’, ‘Email_Address_Goes_Here’);” added to it.