Hi. I am trying to follow the instructions for adding Ecommerce GTM tracking code for product detail views as described on this page - https://docs.kentico.com/k11/e-commerce-features/customizing-and-developing-your-store/integrating-google-analytics-enhanced-ecommerce#IntegratingGoogleAnalyticsEnhancedEcommerce-ViewsofproductdetailsMy product detail page is just a template (.aspx type), not a transformation, but when I try to add the script to the template I get a syntax error saying GetGtmProductJson() doesn't exist in the current context. I am adding it to the template and not via the Javascript web part because I need to pass the SKUID to the method if the template is for a product, and hide the script if not.Can anyone advise how you can add this GTM tracking script to a page template, i.e. is there an import I need to allow the method call? Thanks.
↧