SHARE
TWEET

Untitled

a guest Aug 23rd, 2019 158 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. sellhousefastinbham@gmail.com sent you a conversion tracking tag
  2. The Google Ads user sellhousefastinbham@gmail.com has shared a conversion tracking tag to track clicks on your website as conversions. To add this tag to your website, follow the instructions below.
  3.  
  4. How to use the tag
  5. For conversion tracking to work, you'll need to install the conversion tracking tag, which consists of a global site tag and an event snippet. You'll also need to add code so Google Ads records a conversion only when a customer clicks on a chosen link, button, or image. If installing the tag with Google Tag Manager, follow these instructions instead.
  6.  
  7. If any of your web pages are built using AMP, you'll need to add tags to both the AMP and HTML versions. Instructions are included for both.
  8.  
  9. HTML PAGES
  10.  
  11. Install the global site tag on every page of your website.
  12. Open the HTML for each page.
  13. Choose from the following options:
  14. If you haven't installed the global site tag on your website, copy the tag below and paste it between the head tags (<head></head>):
  15.  
  16. <!-- Global site tag (gtag.js) - Google Ads: 724556459 --> <script async src="https://www.googletagmanager.com/gtag/js?id=AW-724556459"></script> <script> window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'AW-724556459'); </script>
  17.  
  18. See more guidelines on setting up the global site tag.
  19.  
  20. If you installed the global site tag on your website from another Google product (example: Google Analytics) or from another Google Ads account, copy the 'config' command below and add it to every instance of the global site tag, right above the </script> end tag.
  21.  
  22. gtag('config', 'AW-724556459');
  23.  
  24. If you or a manager account already installed the global site tag on your website while setting up the tag for another conversion action, make sure that the tag is on every page of your website and check that the 'config' command has this Google Ads account's conversion ID: AW-724556459
  25. Save the changes to your webpages.
  26.  
  27. Install the event snippet on the page that has the button or link you'd like to track.
  28. Open the HTML for the page.
  29. Copy the snippet below and paste it between the head tags (<head></head>) of the page, right after the global site tag.
  30.  
  31. <!-- Event snippet for Lead from Form Updated 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-724556459/EsLUCMusp6gBEKu1v9kC', 'event_callback': callback }); return false; } </script>
  32.  
  33.  
  34. Add an onclick attribute directly to the code for the button or link you'd like to track. The code you use will depend on how the link or button is displayed on your site: as a text link, button, or button image.
  35.  
  36. Add the code to a text link: In the code below, replace "http://example.com/your-link" with the URL for your website or telephone link, and replace "Download now!" with your link text.
  37.  
  38. <a onclick="return gtag_report_conversion('http://example.com/your-link');" href="http://example.com/your-link">Download now!</a>
  39.  
  40. Add the code to a button: This code shows you how to add click tracking functionality to a button using the <button> tag. Replace "http://example.com/your-link" with the URL for your website.
  41.  
  42. <button onclick="return gtag_report_conversion('http://example.com/your-link')">Submit</button>
  43.  
  44. Add the code to a button image: In the code below, replace "download_button.gif" with your button image, replace the width and height with your image's parameters, and replace "http://example.com/your-link" with the URL for your link.
  45.  
  46. <img src="download_button.gif" alt="Download Whitepaper" width="32" height="32" onclick="return gtag_report_conversion('http://example.com/your-link')" />
  47.  
  48. Save the changes to your webpage.
  49. AMP PAGES
  50.  
  51. You should follow these instructions for any of the pages built using the AMP framework.
  52.  
  53. Install the global site tag on every page of your website.
  54. Open the HTML for each page.
  55. Choose from the following options:
  56. If you haven't installed the global site tag on your website, add these two tags:
  57. First, copy the tag below and paste it between the head tags (<head></head>), before the AMP JS library.
  58.  
  59. <script async custom-element="amp-analytics" src="https://cdn.ampproject.org/v0/amp-analytics-0.1.js"></script>
  60.  
  61. Then, copy the tag below and paste it between the body tags (<body></body>) of all of your AMP pages
  62.  
  63. <!-- Global site tag (gtag) - Google Ads: 724556459 --> <amp-analytics type="gtag" data-credentials="include"> <script type="application/json"> { "vars": { "gtag_id": "AW-724556459", "config": { "AW-724556459": { "groups": "default" } } }, "triggers": { } } </script> </amp-analytics>
  64.  
  65. See more guidelines on setting up the global site tag.
  66. If you installed the global site tag on your website from another Google product (example: Google Analytics) or from another Google Ads account, copy the line below and include it in the "config" section of every instance of the global site tag.
  67.  
  68. "AW-724556459": { "groups": "default" }
  69.  
  70. If you or a manager account already installed the global site tag on your website while setting up the tag for another conversion action, make sure that the tag is on every page of your website and check that the "config" section has this Google Ads account's conversion ID: AW-724556459
  71. Save the changes to your webpages.
  72.  
  73. Install the event snippet on the page that has the button or link you'd like to track.
  74. Open the HTML for the page.
  75. Find a CSS selector for the button or link you'd like to track. For example, you could use "#purchase" or ".out-button" if your button is set up like the following:
  76.  
  77. <button id="purchase" class="out-button">Click</button>
  78.  
  79. Copy the snippet below and paste it into the "triggers" section of the global site tag. Change the value of "selector" to match the clicked item.
  80.  
  81. "C_KxUsc0IQR5E": { "on": "click", "selector": "CSS_SELECTOR", "vars": { "event_name": "conversion", "send_to": ["AW-724556459/EsLUCMusp6gBEKu1v9kC"] } }
  82.  
  83. Save the changes to your webpage.
  84. Learn more about tracking clicks on your website as conversions.
  85.  
  86. Thanks,
  87. The Google Ads Team
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top