本文介绍了Google Analytics(分析)未接收事件(命令已忽略.未知目标:未定义)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以我通过Google跟踪代码管理器设置了Google Analytics(分析).页面浏览量跟踪工作正常.但是,当我尝试跟踪任何事件时,数据只是无法传递到Google Analytics(分析).事件跟踪也不适用于传统的Google Analytics(分析)代码.

So I got my Google Analytics set up via Google Tag Manager. Page views tracking is working fine. But when I try to track any events, the data is just not getting through to Analytics. The event tracking did not work with traditional Analytics code either.

Analytics调试显示了几个创建配置的参数未知:x"和忽略命令.未知目标:未定义"

Analytics debug is showing several "Create config had an unknown parameter: x"and "Command ignored. Unknown target: undefined"

据说这意味着我的跟踪器名称有问题.我尝试了默认名称和自定义名称.

Supposedly this means that there is something wrong with my tracker name. I have tried both default name and custom names.

也许值得一提:直到最近,我的网站的默认URL在Google Analytics(分析)网站偏好设置中还是错误的,但是我不确定这是否与此有关.

Might be worth mentioning: Until recently, my site's default URL was wrong in Analytics site preferences, but I'm not sure if that has anything to do with this.

分析调试消息:

Executing Google Analytics commands.
analytics_debug.js:10 Running command: ga("create", {2: null, 3: null, 6: "1", 10: false, 11: false, 12: false, 16: false, 17: false, 18: false, 28: false, 32: "UA-1439995-1", 33: false, 34: false, 35: [{fieldName: "cookieDomain", value: "auto"}]}, {name: "gtm5"})
analytics_debug.js:10 Creating new tracker: t0
analytics_debug.js:10 Create config had an unknown parameter: "2"
analytics_debug.js:10 Create config had an unknown parameter: "3"
analytics_debug.js:10 Create config had an unknown parameter: "6"
analytics_debug.js:10 Create config had an unknown parameter: "10"
analytics_debug.js:10 Create config had an unknown parameter: "11"
analytics_debug.js:10 Create config had an unknown parameter: "12"
analytics_debug.js:10 Create config had an unknown parameter: "16"
analytics_debug.js:10 Create config had an unknown parameter: "17"
analytics_debug.js:10 Create config had an unknown parameter: "18"
analytics_debug.js:10 Create config had an unknown parameter: "28"
analytics_debug.js:10 Create config had an unknown parameter: "32"
analytics_debug.js:10 Create config had an unknown parameter: "33"
analytics_debug.js:10 Create config had an unknown parameter: "34"
analytics_debug.js:10 Create config had an unknown parameter: "35"
Executing Google Analytics commands.
analytics_debug.js:10 Running command: ga("gtm5.set", "&gtm", "G32NJ6NK7K")
analytics_debug.js:10 Command ignored. Unknown target: undefined
analytics_debug.js:10 Executing Google Analytics commands.
analytics_debug.js:10 Running command: ga("gtm5.set", "nonInteraction", false)
analytics_debug.js:10 Command ignored. Unknown target: undefined
analytics_debug.js:10 Executing Google Analytics commands.
analytics_debug.js:10 Running command: ga("gtm5.set", "hitCallback", [function])
analytics_debug.js:10 Command ignored. Unknown target: undefined
analytics_debug.js:10 Executing Google Analytics commands.
analytics_debug.js:10 Running command: ga("gtm5.send", {hitType: "event", eventCategory: "contact-form", eventAction: "successful-form-submission-mailsent", eventLabel: "362", eventValue: undefined})
analytics_debug.js:10 Command ignored. Unknown target: undefined

分析调试消息屏幕截图

推荐答案

我相信我已经找到了解决方案.

I believe I have found a solution.

我通过将跟踪器名称设置为空白,在GTM中编辑了我的Universal Analytics标签(联系表单提交和GA-Pageview).

I edited my Universal Analytics tags (Contact Form Submission and GA-Pageview) in GTM by setting tracker names to blank.

(编辑标签->启用此标签中的替代设置->更多设置->高级配置->设置跟踪器名称[True]

(Edit Tag -> Enable overriding settings in this tag -> More Settings -> Advanced Configuration -> Set Tracker Name [True]

我不知道为什么我必须这样做,如果这是一个很好的解决方案,我也不知道.但是现在事件跟踪似乎可以了.

I have no idea why I had to do this and if this is a good solution. But now event tracking seems to work.

这篇关于Google Analytics(分析)未接收事件(命令已忽略.未知目标:未定义)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-03 19:42