SHOW:
|
|
- or go back to the newest paste.
| 1 | - | //Push this dataLayer event when the user clicks on a CTA button in the hero banner section of the page. |
| 1 | + | //Push this dataLayer event when the user clicks on a regular CTA button or text (hero CTA excluded). Do not push this event if some other event is firing here, e.g. product_click, file_download, etc. |
| 2 | ||
| 3 | <script> | |
| 4 | window.dataLayer = window.dataLayer || []; | |
| 5 | window.dataLayer.push({
| |
| 6 | - | 'event': 'hero_cta_click', |
| 6 | + | 'event': 'cta_click', |
| 7 | - | 'page_section': '<hero banner title>', //Section of the page where the event happened. |
| 7 | + | 'page_section': 'talk to a specialist', //Section of the page where the event happened. |
| 8 | - | 'click_element': 'get in touch', //Text or description of the element that was clicked on. |
| 8 | + | 'click_element': 'contact us', //Text or description of the element that was clicked on. |
| 9 | 'content_group': '<content_group>', //Content group that the link belongs to. (include only if applicable - e.g. for "view more" buttons) | |
| 10 | 'ui_element_name': '<ui_element_name>', //The name of the UI element from the Zeplin file. | |
| 11 | 'ui_element_category': '<ui_element_category>' //The category of the UI element. | |
| 12 | }); | |
| 13 | </script> |