简体   繁体   English

具有两个onClick操作的Google Analytics(分析)虚拟网页浏览量

[英]Google Analytics Virtual Pageview with two onClick actions

I have been trying to get the following code to work: 我一直在尝试使以下代码起作用:

<button type="button" onclick="productAddToCartForm.submit(this); _gaq.push(['_trackPageview','/checkout/addtocart/'])">

The submit action is working as it should, but the Virtual PageView is not working at all. 提交操作正在按预期方式工作,但是虚拟PageView根本无法工作。

Check the code on your site. 检查您网站上的代码。 Your analytics code might be run using a diffrent Variable name. 您的分析代码可能使用不同的变量名称运行。 For example on my site its: 例如在我的网站上:

var _gaq = _gaq || [];

另外,我建议事件跟踪将是一种更好的跟踪方式,因为它不会增加总的浏览量,并为您提供更多的见解。

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

相关问题 将变量插入onClick事件Google Analytics(分析)虚拟综合浏览量 - Insert variable into onClick event Google Analytics virtual pageview 虚拟网页浏览代替Google Analytics中的真实网页浏览 - Virtual pageview in place of real pageview in Google Analytics 使用Google跟踪代码管理器将综合浏览量发送到虚拟URL到Google Analytics(分析) - Send pageview to virtual URL with google tag manager to google analytics Google Analytics(分析)虚拟综合浏览量跟踪代码不一致地记录了综合浏览量 - Google Analytics virtual pageview tracking code inconsistently records pageviews 如何在模式窗口上编写Google Analytics(分析)虚拟综合浏览量的代码 - How to code a Google Analytics virtual pageview on a modal windows 适用于Ajax网站的Google Analytics(分析)浏览量 - google analytics pageview for ajax website Google Analytics(分析):结合事件和综合浏览量 - Google Analytics: Combine event and pageview 谷歌标签管理器虚拟浏览量 - google tag manager virtual pageview Google Analytics(分析) - 跟踪iframe中的事件,但不跟踪综合浏览量 - Google analytics - Track events in iframe but not the pageview Google Analytics(分析)核心报告API浏览量标签? - Google analytics core reporting api pageview label?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM