Cordova谷歌标签管理器(GTM) - 无法看到分析的点击率

时间:2021-12-03 14:08:58

I'm having problems integrating cordova-plugin-tag-manager. I've installed plugin and configured GTM ID in project. Success and Error callbacks seems to be working on android (I've debugged with LogCat), I'm having response from GTM, but can't see hits on analytics realtime report.

我在整合cordova-plugin-tag-manager方面遇到了问题。我在项目中安装了插件并配置了GTM ID。成功和错误回调似乎在Android上运行(我已经使用LogCat进行了调试),我收到了GTM的回复,但无法看到分析实时报告的点击量。

1 个解决方案

#1


-1  

I've found a solution. You must configure GTM tags like said in this plugin wiki page to have hits on analytics report:

我找到了解决方案。您必须像在此插件维基页面中所述配置GTM标记才能获得分析报告:

https://github.com/kraihn/cordova-plugin-tag-manager/wiki/GTM-Setup

https://github.com/kraihn/cordova-plugin-tag-manager/wiki/GTM-Setup

Setup listeners in Google Tag Manager

在Google跟踪代码管理器中设置侦听器

6 User-Defined Variables

6个用户定义的变量

  • Variable Name: page path Variable Type: Data Layer Variable Data Layer Variable Name: content-name
  • 变量名称:页面路径变量类型:数据层变量数据层变量名称:content-name
  • Variable Name: event category Variable Type: Data Layer Variable Data Layer Variable Name: target
  • 变量名称:事件类别变量类型:数据层变量数据层变量名称:目标
  • Variable Name: event action Variable Type: Data Layer Variable Data Layer Variable Name: action
  • 变量名称:事件操作变量类型:数据层变量数据层变量名称:操作
  • Variable Name: event label Variable Type: Data Layer Variable Data Layer Variable Name: target-properties
  • 变量名称:事件标签变量类型:数据层变量数据层变量名称:目标属性
  • Variable Name: event value Variable Type: Data Layer Variable Data Layer Variable Name: value
  • 变量名称:事件值变量类型:数据层变量数据层变量名称:值
  • Variable Name: event interaction type Variable Type: Data Layer Variable Data Layer Variable Name: interaction-type
  • 变量名称:事件交互类型变量类型:数据层变量数据层变量名称:interaction-type

2 Triggers

2触发器

  • Trigger Name: events, Choose Event: Custom, Fire On: {{event}} equals interaction
  • 触发器名称:事件,选择事件:自定义,开启:{{event}}等于交互
  • Trigger Name: pageviews, Choose Event: Custom, Fire On: {{event}} equals content-view
  • 触发器名称:综合浏览量,选择事件:自定义,开启:{{event}}等于内容视图

2 Tags

2个标签

  • Tag Name: Events, Tag Type: Universal Analytics, Tracking ID: YourGoogleAnalyticsID, Track Type: Event, Category: {{event category}}, Action: {{event action}}, Label: {{event label}}, Value: {{event value}} Fields to Set: appName = {{App Name}}, appVersion = {{App Version Code}}, screenName = {{page path}}, Firing On: events

    标记名称:事件,标记类型:通用分析,跟踪ID:YourGoogleAnalyticsID,跟踪类型:事件,类别:{{事件类别}},操作:{{事件操作}},标签:{{事件标签}},值: {{event value}}要设置的字段:appName = {{App Name}},appVersion = {{App Version Code}},screenName = {{page path}},Firing On:events

  • Tag Name: Pageviews, Tag Type: Universal Analytics, Tracking ID: YourGoogleAnalyticsID, Track Type: App View, Fields to Set: appName = {{App Name}}, appVersion = {{App Version Code}}, screenName = {{page path}}, Firing On: pageviews

    标记名称:网页浏览,标记类型:通用Analytics(分析),跟踪ID:YourGoogleAnalyticsID,轨道类型:应用程序查看,要设置的字段:APPNAME = {{应用程序名称}},appVersion = {{应用程式版本代码}},屏幕名= {{页path}},Firing On:网页浏览量

#1


-1  

I've found a solution. You must configure GTM tags like said in this plugin wiki page to have hits on analytics report:

我找到了解决方案。您必须像在此插件维基页面中所述配置GTM标记才能获得分析报告:

https://github.com/kraihn/cordova-plugin-tag-manager/wiki/GTM-Setup

https://github.com/kraihn/cordova-plugin-tag-manager/wiki/GTM-Setup

Setup listeners in Google Tag Manager

在Google跟踪代码管理器中设置侦听器

6 User-Defined Variables

6个用户定义的变量

  • Variable Name: page path Variable Type: Data Layer Variable Data Layer Variable Name: content-name
  • 变量名称:页面路径变量类型:数据层变量数据层变量名称:content-name
  • Variable Name: event category Variable Type: Data Layer Variable Data Layer Variable Name: target
  • 变量名称:事件类别变量类型:数据层变量数据层变量名称:目标
  • Variable Name: event action Variable Type: Data Layer Variable Data Layer Variable Name: action
  • 变量名称:事件操作变量类型:数据层变量数据层变量名称:操作
  • Variable Name: event label Variable Type: Data Layer Variable Data Layer Variable Name: target-properties
  • 变量名称:事件标签变量类型:数据层变量数据层变量名称:目标属性
  • Variable Name: event value Variable Type: Data Layer Variable Data Layer Variable Name: value
  • 变量名称:事件值变量类型:数据层变量数据层变量名称:值
  • Variable Name: event interaction type Variable Type: Data Layer Variable Data Layer Variable Name: interaction-type
  • 变量名称:事件交互类型变量类型:数据层变量数据层变量名称:interaction-type

2 Triggers

2触发器

  • Trigger Name: events, Choose Event: Custom, Fire On: {{event}} equals interaction
  • 触发器名称:事件,选择事件:自定义,开启:{{event}}等于交互
  • Trigger Name: pageviews, Choose Event: Custom, Fire On: {{event}} equals content-view
  • 触发器名称:综合浏览量,选择事件:自定义,开启:{{event}}等于内容视图

2 Tags

2个标签

  • Tag Name: Events, Tag Type: Universal Analytics, Tracking ID: YourGoogleAnalyticsID, Track Type: Event, Category: {{event category}}, Action: {{event action}}, Label: {{event label}}, Value: {{event value}} Fields to Set: appName = {{App Name}}, appVersion = {{App Version Code}}, screenName = {{page path}}, Firing On: events

    标记名称:事件,标记类型:通用分析,跟踪ID:YourGoogleAnalyticsID,跟踪类型:事件,类别:{{事件类别}},操作:{{事件操作}},标签:{{事件标签}},值: {{event value}}要设置的字段:appName = {{App Name}},appVersion = {{App Version Code}},screenName = {{page path}},Firing On:events

  • Tag Name: Pageviews, Tag Type: Universal Analytics, Tracking ID: YourGoogleAnalyticsID, Track Type: App View, Fields to Set: appName = {{App Name}}, appVersion = {{App Version Code}}, screenName = {{page path}}, Firing On: pageviews

    标记名称:网页浏览,标记类型:通用Analytics(分析),跟踪ID:YourGoogleAnalyticsID,轨道类型:应用程序查看,要设置的字段:APPNAME = {{应用程序名称}},appVersion = {{应用程式版本代码}},屏幕名= {{页path}},Firing On:网页浏览量