I need to include a Google Ads tracking tag in a form's "Submit" button.
Google tells me to add this script into page:
<!-- Event snippet for Solicitar proposta conversion page In your html page, add the snippet and call gtag_report_conversion when someone clicks on the chosen link or button. --> <script> function gtag_report_conversion(url) { var callback = function () { if (typeof(url) != 'undefined') { window.location = url; } }; gtag('event', 'conversion', { 'send_to': 'AW-XXXXXXX/XXXXXXXXXXXXXX', 'event_callback': callback }); return false; } </script>
And on the submit button, put the following code:
<button onclick="return gtag_report_conversion('http://example.com/your-link')">Enviar</button>
How can I do this on ToWeb?