I would like to get a functionality set up on my form where it pushes the GA client ID from the GA cookie into a hidden field in the HubSpot form with a script of Java (Jquery). I did some research and found a site that explained how it is possible here.
The script that I took from there is:
var clientId = ga.getAll().get(‘clientId’);
The trouble that I am having is that I’m not sure what exactly the variables are within the script and what they should be changed to to get the function working on my specific form. It also does not explain where the script should go. Would it go in the header of the page or in the embed code of the form.
I’m sorry if it seems like a dumb question, I’m not too experienced with this.