简体   繁体   English

Google 跟踪代码管理器 - 产品页面上的图像跟踪

[英]Google Tag Manager - Image Tracking on product page

I am working on a Shopify website, I want to track how users interact with images on the product page.我正在开发一个 Shopify 网站,我想跟踪用户如何与产品页面上的图像进行交互。 let's say a user sees the first image (a tag should fire), then he scrolls on the second product image (another tag should fire), and so on.假设用户看到第一个图像(应该触发一个标签),然后他滚动到第二个产品图像(应该触发另一个标签),依此类推。

So I can know how many images on average the user sees on a PDP, what is the conversion rate of users who see 2 images vs 3 images, etc. (On GA)所以我可以知道用户在 PDP 上平均看到多少张图片,看到 2 张图片与 3 张图片的用户的转化率是多少等。(在 GA 上)

This would require a custom javascript event which has to be passed on GTM, I looked at different resources available but could not find the right way.这将需要一个自定义的 javascript 事件,该事件必须在 GTM 上传递,我查看了不同的可用资源,但找不到正确的方法。

Any help with how to proceed with this, or resources I can refer to would help.任何有关如何进行此操作的帮助或我可以参考的资源都会有所帮助。

I think you can try the element visibility trigger.我认为您可以尝试element visibility触发器。

Here is the setting detail这是设置细节

  1. Add a good name about it.添加一个好名字。

  2. Choose the CSS Selector since you have multiple images.选择 CSS 选择器,因为您有多个图像。

  3. Set the right CSS Selector.设置正确的 CSS 选择器。 If you don't know how to set it.如果你不知道如何设置它。 You might need to give us the URL of your website and we can provide you the selector.您可能需要给我们您网站的 URL,我们可以为您提供选择器。

  4. Choose Once Per Element Once Per Element

  5. You can decide when the image shows more than x%.您可以决定图像何时显示超过 x%。 Fire the trigger.触发扳机。

在此处输入图像描述


Since you need the order of the image.由于您需要图像的顺序。 You can refer about this你可以参考这个

#GTMTIPS: GET POSITION INDEX OF VISIBLE ELEMENT #GTMTIPS:获取可见元素的 POSITION 索引

If you have further question.如果您还有其他问题。 Feel free to leave comment and I'll update accordingly随时发表评论,我会相应地更新

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM