Skip to Content Skip to Menu

🎃 Happy Halloween! Treat yourself with an awesome discount on memberships! Get 20% off now with code SPOOKY-2024!

[SOLVED] Registration tracking with goals in GA

  • krileon
  • krileon
  • ONLINE
  • Posts: 48459
  • Thanks: 8280
  • Karma: 1443
12 years 1 month ago #209089 by krileon
Replied by krileon on topic Re: Registration tracking with goals in GA
You'll probably need 2 auto actions. The first one would load in the Google Analytics JS. The second one would fire your tracking JS. Both would be Code actions; the first one would be JS (URL) and the second would be JS (Inline).

If I set 'Access' in CB AutoActions plugin for "Job Seeker" (one of my User Groups), will CBSubs add that user group to the user before CBAutoActions runs onAfterUserRegistration?

No, the after registration trigger is fired before CBSubs.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • citydan
  • citydan
  • OFFLINE
  • Posts: 44
  • Thanks: 2
  • Karma: 1
12 years 1 month ago - 12 years 1 month ago #209097 by citydan
Replied by citydan on topic Re: Registration tracking with goals in GA

krileon wrote: You'll probably need 2 auto actions. The first one would load in the Google Analytics JS. The second one would fire your tracking JS. Both would be Code actions; the first one would be JS (URL) and the second would be JS (Inline).


I am already using the Google Analytics integration for CBSubs AND have Google Analytics in a module in my footer, so the GA JS should be loaded already. However, as it's in the footer, it comes up last in the source code. I will see if I can use my template to load the GA JS in the header... but if it's the asynchronous Google Analytics code, will it load too late?

As for the second JS (Inline) I can't get it to work. I've got three different lines of attempted js but none of them are working. They are showing up in the source code of the registration thankyou message, but no alert is coming up.
Code:
<script type="text/javascript" onload="alert('Registration Successful');"></script> onload="alert('Registration Successful - Basic');" alert("Welcome!");

If I set 'Access' in CB AutoActions plugin for "Job Seeker" (one of my User Groups), will CBSubs add that user group to the user before CBAutoActions runs onAfterUserRegistration?

No, the after registration trigger is fired before CBSubs.[/quote]

This is too bad. Do you have any other suggestions for how I can track different types of registrations then?
Last edit: 12 years 1 month ago by citydan.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48459
  • Thanks: 8280
  • Karma: 1443
12 years 1 month ago #209103 by krileon
Replied by krileon on topic Re: Registration tracking with goals in GA
CBSubs doesn't execute until after the registration trigger. So no, the JS won't be prepared when using the after user registration trigger. If is in a module that is present on all pages then yes it should be on every page assuming the module loads before the plugin. In that case you should be able to just use a Code action with a method of JS (Inline). Should be able to confirm if it's working by watching browser error console and set it to persist through page loads.

Do you have any other suggestions for how I can track different types of registrations then?

If you've email confirmation or admin approval you could use one of those triggers.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • citydan
  • citydan
  • OFFLINE
  • Posts: 44
  • Thanks: 2
  • Karma: 1
12 years 1 month ago #209123 by citydan
Replied by citydan on topic Re: Registration tracking with goals in GA
Ok, for the sake of anyone else trying to do this for the Inline JS method I was able to get the following working:
Code:
alert("Welcome!");

So I have replaced that with:
Code:
_gaq.push(['_trackEvent', 'Registration', 'New User']);

Hope it works. I am using the asynchronous Google Analytics code that is integrated with the Gantry template framework.

This will track all new registrations and should start to show up in Google Analytics Events in a day or two.

To track CBSubs subscriptions I will use a similar GA call in each of the html confirmation messages for each CBSubs subscription:
Code:
<script type="text/javascript"><!-- _gaq.push(['_trackEvent', 'Subscription', 'Plan Name']); --></script>
The following user(s) said Thank You: krileon

Please Log in or Create an account to join the conversation.

  • pwerner
  • pwerner
  • OFFLINE
  • Posts: 21
  • Thanks: 1
  • Karma: 0
11 years 8 months ago #221341 by pwerner
Replied by pwerner on topic Re: Registration tracking with goals in GA
I am just trying to setup a simple conversion link to my google adwrods/analytics account...do you know where I can put their tracking code so that after submitting registration the following screen is seen as a conversion? I cant seem to find the html file that controls that registrations successful page. Any feedback or help would be appreciated.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48459
  • Thanks: 8280
  • Karma: 1443
11 years 8 months ago #221359 by krileon
Replied by krileon on topic Re: Registration tracking with goals in GA
Use CB Auto Actions to do that. You'd use a Code action with the after registration trigger then use one of the JS methods to add JS to the page.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum