Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

Google Ecommerce

jasonw_blinds
Level 1
Level 1

Is there any standard documentation on how to deploy Google Analytics ecommerce in DTM?  I can do the variable assignment but I am not sure if you should call the code in a rule or in the Google Analytics tool area.

1 Accepted Solution
ParitMittal
Correct answer by
Level 10
Level 10

Hi Jason,

Apologies for the delayed response !!!!. I hope we can still help you with your query.

There is no as such standard documentation provided by Adobe for deploying Google Analytics Ecommerce Tracking However Please go through the below steps for implementing the same :

If you are currently using ga.js, you will need to first migrate to analytics.js before using the enhanced ecommerce plug-in. Transaction and item data previously collected using the ecommerce.js plug-in will not be affected by the migration and will remain available in the properties and profiles to which they were originally sent. Please see the following link for more information regarding the same.  https://developers.google.com/analytics/devguides/collection/analyticsjs/enhanced-ecommerce

To include ecommerce or advanced ecommerce library you have to setup the require in the GA tool pageCode. Something like:

ga('require', 'ec');
To use it you have to create custom third party tag in the correct pageLoad rule in order to setup advanced ecommerce tracking, something like:

ga('ec:setAction', 'purchase', {
      id: s_orderid,
      affiliation: s_orderid,
      revenue: order_total,
      tax: '0',
      shipping: pageViewData.shipment_cost,
      coupon: ''
    });
ga('send', 'pageview');
Be sure to prevent in the tool custom page code the standard page view using the commend:

return false
When the ecommerce page load rule is running.

Thanks & Regards

Parit Mittal

View solution in original post

1 Reply
ParitMittal
Correct answer by
Level 10
Level 10

Hi Jason,

Apologies for the delayed response !!!!. I hope we can still help you with your query.

There is no as such standard documentation provided by Adobe for deploying Google Analytics Ecommerce Tracking However Please go through the below steps for implementing the same :

If you are currently using ga.js, you will need to first migrate to analytics.js before using the enhanced ecommerce plug-in. Transaction and item data previously collected using the ecommerce.js plug-in will not be affected by the migration and will remain available in the properties and profiles to which they were originally sent. Please see the following link for more information regarding the same.  https://developers.google.com/analytics/devguides/collection/analyticsjs/enhanced-ecommerce

To include ecommerce or advanced ecommerce library you have to setup the require in the GA tool pageCode. Something like:

ga('require', 'ec');
To use it you have to create custom third party tag in the correct pageLoad rule in order to setup advanced ecommerce tracking, something like:

ga('ec:setAction', 'purchase', {
      id: s_orderid,
      affiliation: s_orderid,
      revenue: order_total,
      tax: '0',
      shipping: pageViewData.shipment_cost,
      coupon: ''
    });
ga('send', 'pageview');
Be sure to prevent in the tool custom page code the standard page view using the commend:

return false
When the ecommerce page load rule is running.

Thanks & Regards

Parit Mittal

View solution in original post