We have 'Send' button in one of our form which locates in website. I try to perform integration between Google Tag Manager and Hubspot, and for the accurate results I need to determine 'click text' for some buttons.
When I check some buttons' click text, it says 'undefined'. That's why I want to give specific name them to get accurate Google Tag manager analysis and precise intergration. How can I add 'click text's to my buttons?
Apr 15, 20214:55 AM - edited Apr 15, 20214:56 AM
HubSpot Employee
Adding 'click text' to CTAs/buttons
SOLVE
Hello. That screenshot looks like an embedded HubSpot form or perhaps a HubSpot popup form. In either case, I think you don't have much control over the markup, "awkward" or not (cf. developer documentation here).
You mention there is a CTA that *does* have the sort of markup you are looking for. Can you maybe share a link, or explain whether it is also in a form or a standalone CTA (the latter is a separate tool, so the markup would be expected to be different from the submit button in a form)?
Since you want to trigger off a HubSpot form submission, I think you can use "global form events", see https://legacydocs.hubspot.com/global-form-events These events should reliably occur in the course of any HubSpot form submission.
Apr 15, 20214:55 AM - edited Apr 15, 20214:56 AM
HubSpot Employee
Adding 'click text' to CTAs/buttons
SOLVE
Hello. That screenshot looks like an embedded HubSpot form or perhaps a HubSpot popup form. In either case, I think you don't have much control over the markup, "awkward" or not (cf. developer documentation here).
You mention there is a CTA that *does* have the sort of markup you are looking for. Can you maybe share a link, or explain whether it is also in a form or a standalone CTA (the latter is a separate tool, so the markup would be expected to be different from the submit button in a form)?
Since you want to trigger off a HubSpot form submission, I think you can use "global form events", see https://legacydocs.hubspot.com/global-form-events These events should reliably occur in the course of any HubSpot form submission.
For the first one, we have a button called "Subscribe" in our website. When I clicked it, it has awkard click class and its click element is general. The other elements such as Click Text is also undefined as you can see. That's why I can't track the event for the clicking subscription. In addition, I can't define any click text to this button same as "Send" button.
However, some of other CTA's has proper click text, for example;
For the second one, the other tags and events installed correctly, and I can check it from the Google Tag Assistant. My challenge is having trouble with defining events/tags with some CTAs