Documentation You are here: start » v » 2.0 » analytics

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
v:2.0:analytics [2024/12/05 09:11] – [Supported Events] adamv:2.0:analytics [2025/09/05 13:34] (current) – [Google Tag Manager] adam
Line 76: Line 76:
  
 You can see [[https://developers.google.com/analytics/devguides/collection/ga4/ecommerce?client_type=gtag#view_item_details|details on the ''view_item'' event on the GA4 documentation here]]. You can see [[https://developers.google.com/analytics/devguides/collection/ga4/ecommerce?client_type=gtag#view_item_details|details on the ''view_item'' event on the GA4 documentation here]].
 +
 +=== Item data ===
  
 As a reference, for the Foxy integration, we pass the following attributes for ''items'' in GA4 ecommerce event calls: As a reference, for the Foxy integration, we pass the following attributes for ''items'' in GA4 ecommerce event calls:
Line 104: Line 106:
  
 Specifically for GTM, there is also one additional custom event for ''virtual_page_view''. This is triggered when the Sidecart is opened, along with when the cart, checkout and receipt are loaded. It's up to you if you want to include this for your set up to track clean URL's for the page views for those aspects as well, instead of the default page view. The dataLayer for this event passes a ''virtual_page_location'' parameter with the clean URL, along with a ''virtual_page_title'' parameter to match to the ''page_title'' for the page view event. Note that for events that occur on your website (for example, for ''add_to_cart'', ''remove_from_cart'' or ''view cart'' that happen via the Sidecart), the ''virtual_page_location'' will be your website URL. Specifically for GTM, there is also one additional custom event for ''virtual_page_view''. This is triggered when the Sidecart is opened, along with when the cart, checkout and receipt are loaded. It's up to you if you want to include this for your set up to track clean URL's for the page views for those aspects as well, instead of the default page view. The dataLayer for this event passes a ''virtual_page_location'' parameter with the clean URL, along with a ''virtual_page_title'' parameter to match to the ''page_title'' for the page view event. Note that for events that occur on your website (for example, for ''add_to_cart'', ''remove_from_cart'' or ''view cart'' that happen via the Sidecart), the ''virtual_page_location'' will be your website URL.
 +
 +=== GTM ''daterLayer'' event ===
 +
 +If you want to add custom tracking for GTM to pass through additional values than what Google Analytics/Ads needs - for example for other integrations - you can do that using the ''analytics-gtm-datalayer'' JS event. You can see details on using this event [[.:javascript#eventswhat_they_are_and_how_to_use_them|within our javascript events documentation]].
 +
 +As a quick example, this would add an additional parameter called ''foo'' with a value of ''bar'' to be sent with the dataLayer's data:
 +
 +<code javascript>
 +FC.client.on('analytics-gtm-datalayer', function(params) {
 +    params.event_data.foo = "bar";
 +});
 +</code>
  
 === GTM Screenshots === === GTM Screenshots ===

Site Tools