I have been trying to add GA event triggered when a form is filled on my landing page. The problem is that the form is not embeded, but rather a part of a landing page designed in Hubspot. I contacted the support and the told me, there is no way to do that, but it is possible when embeding the form on a separate website.
This got me thinking, what if I embed the code in the rich text module? Theretically this should work, according to HubSpot support, but I'm having trouble making it work.
I can embed my form using the code provided byy Hubspot (embed form) - it works fine
However, when I try to add the GA part, the form does not display at all
What makes it more complicated, is that once I remove the css: "" bit, the form is displayed (with default styling thought), but the GA event is not triggered upon submission. My knowledge of scripts and or php is limitted, but I think I've tried many different solutions from the hubspot community - none of the work
Can anyone advise?
P.S.: Naturally, I have GA tracking code in the header of the landing page.