Expand my Community achievements bar.

DCM Pixel implementation on Thanks you Page

Avatar

Level 1

Hi Team,

Can someone help me how to convert the given pixel to fire on the Order confirmation (Thank you) Page. I would be very thankful if you help me with what is the exact code need to be written. I'm working for the first time on Third Party Pixels.

<!--

Event snippet for Thank you pixel on https://www.xyz.com: Please do not remove.

Place this snippet on pages with events you’re tracking.

Creation date: 06/25/2018

-->

<script>

  gtag('event', 'purchase', {

    'allow_custom_scripts': true,

    'value': '[Revenue]',

    'transaction_id': '[OrderID]',

    'quantity': '[Quantity]',

    'u1': '[Product_Id]',

    'u2': '[Product_Revenue]',

    'send_to': 'DC-1234567/thank0/thank0+items_sold'

  });

</script>

<noscript>

<img src=""https://ad.doubleclick.net/ddm/activity/src=1234567;type=thank0;cat=thank0;qty=[Quantity];cost=[Reve...?"" width=""1"" height=""1"" alt=""""/>

</noscript>

<!-- End of event snippet: Please do not remove -->"

Awaiting for the assistance as earliest.

Thanks,

Balakrishna

1 Reply

Avatar

Level 10

Hi Balakrishna,

It looks like the code you've provided is HTML code. If you only want this code to fire on your thank you page, I'd recommending creating a page load rule in DTM with conditions to limit it to only fire on your thank you page.

To limit the rule to only fire on the thank you page, you could likely use something like the path condition. You would then place the URL unique to the thank you page in the value field of the path condition.

Once you've got the rule condition configured, you'll want to add your code in the "Javascript/Third Party Tags" section. Inside that section, you'll see three tabs. For you're code snippet, you'll want to use the sequential HTML tab.

Hopefully this helps,

Jantzen