谷歌分析跟踪单页结账中的退出 [英] Google analytics track exits within a one-page checkout

查看:26
本文介绍了谷歌分析跟踪单页结账中的退出的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用一个名为 NopCommerce 的电子商务系统,该系统实现了单页结账系统.此页面要求用户在付款前填写账单地址/送货地址等详细信息.

I'm using an ecommerce system called NopCommerce that implements a one page checkout system. This page asks users to fill out details like billing address / shipping address etc before taking payment.

页面使用 ajax 来保存这些细节,所以 URL 不会改变,没有内部锚点等来标记进度.

The page uses ajax to save these details so the URL doesn't change, there's no internal anchors etc to mark progress.

有谁知道是否可以使用 Google 分析来找出人们在此页面上退出的位置?

Does anyone know if it's possible using Google analytics to find out where on this page people are exiting?

我知道有退出报告,但它们只涉及页面,而不是页面内的区域.

I know there are exit reports but they just refer to pages, not areas within pages.

这可能吗?如果可能,它是如何实施的?

Is this possible and if so how is it implemented?

推荐答案

我不知道 Nopcommerce,但正在查看 演示 似乎各个步骤是使用 jquery 通过 ajax 加载的,这意味着您可以使用 全局 ajax 事件处理程序 为每个结帐步骤发送一个虚拟浏览量:

I do not know Nopcommerce, but looking at the demo it seems the individual steps are loaded via ajax using jquery, which means you can use global ajax event handlers to send a virtual pageview for each checkout step:

$(document).ajaxSuccess(function(event, xhr, settings ) {
  url = settings.url.replace("https://mydomain.com","");
  ga('send', 'pageview', url);
});

未经测试,但我在 magento onepage 结帐时使用了类似的东西,所以我确定它会起作用(可能需要稍作调整).

Untested, but I'm using something similar for the magento onepage checkout so I'm certain it will work (maybe needs a little tweaking).

在全局 ajax 处理程序回调 settings.url 中存储已通过 ajax 调用的 url,并且由于您将路径传递到 Analytics 虚拟浏览量,而不是完整的 url,因此您需要从中删除协议和主机名设置.url.

In the global ajax handler callback settings.url stores the url that has beed called via ajax and since you pass a path to an Analytics virtual pageview, not the full url, you'd need to remove the protocol and host name from settings.url.

这篇关于谷歌分析跟踪单页结账中的退出的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆