• Hi Thomas,

    thanks for this great plugin and also your fast support I see you give on other threads. I hope you can help me as well.

    The datalayer is something quite complex, especially for not so tech-savvy people as I am ?? I managed to set up your plugin, also the enhanced GA tracking and so forth but struggling with one issue. And I a not sure whether I just missed something or totally misunderstood the whole GTM.

    I want to integrate a tag from a 3rd party, lets say its a retargeting company. They require to pass them the following variables in the tag on the thankyou page:
    – Total Revenue
    – Currency
    – Transaction ID
    – Number of products purchased
    – Price of each product
    and so on

    My question: I stumbled upon “total revenue” before in the Google Adwords Tag and I know that this is the variable “transactionTotal”. But what about the others? Are those also transmitted through the datalayer of your plugin (I use woocommerce)? Or do i need to setup those myself? Is there some kind of list with all existing variables?

    I hope you understand the problem I have with the layer & variables.
    My site is: https://www.greenyogashop.com

    Thanks and all the best
    Sonic

    https://www.ads-software.com/plugins/duracelltomi-google-tag-manager/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter Sonic55

    (@sonic55)

    Hi Thomas (or anyone else),

    it would be great if you could give me feedback on this.

    Thanks a lot and all the best
    Stefan

    Plugin Author Thomas Geiger

    (@duracelltomi)

    Hi,

    I will go through all open thread in a couple of hours.

    Thomas

    Thread Starter Sonic55

    (@sonic55)

    Hi Thomas,

    I dont want to bug you, but did you have a chance yet to look into my question?

    Thanks
    Sonic

    Plugin Author Thomas Geiger

    (@duracelltomi)

    Hi Sonic,

    First of all: I apologize for such a delay.

    Second: are you using classic ecommerce tracking or enhanced ecommerce tracking? Either way all your requested data is available in the dataLayer.

    For example: if you are using classic ecommerce, you should use the datalayer variable transactionId
    The same in enhanced ecommerce can be accessed using the datalayer variable ecommerce.purchase.actionField.id

    For currency and classic ecommerce you can use transactionCurrency
    There is currently no equivalent in enhanced ecommerce but this should be added to the plugin and I added it to the todo list.

    Number of products is a but tricky, you will need to create a datalayer variable to access the transactionProducts variable for classic ecommerce or the ecommerce variable for enhanced ecommerce.
    Then you need to create a new JavaScript variable:

    function() {
      return {{transactionProducts}}.length;
    }

    or for enhanced ecommerce

    function() {
      return {{ecommerce}}.purchase.products.length;
    }

    I assume you use the same names on the GTM UI for the variables as they are named in the datalayer.

    Price of each product: this is tricky as well as you will need another JS variable. Do you need to total value of the purchase or the price of a specific product?

    Cheers,
    Thomas

    Thread Starter Sonic55

    (@sonic55)

    Hi Thomas,

    thanks a ton for your elaborate answer. I just wrote you a private message with a professional enquiry.

    Thanks
    Sonic

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Variables for E-Commerce Pixels’ is closed to new replies.