基于跨平台JavaScript的移动应用程序的分析 [英] Analytics for cross platform JavaScript based mobile app

查看:74
本文介绍了基于跨平台JavaScript的移动应用程序的分析的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

可能重复:
如何在没有插件的情况下将Google Analytics(分析)与Phonegap一起使用?/a>

Possible Duplicate:
How to use Google Analytics with Phonegap without a plugin?

我想使用 Phonegap 之类的东西来编写适用于Android,iOS和Blackberry的应用程序,并生成免费的分析数据,例如会话长度和按下按钮的频率. 我希望能够在JavaScript中进行所有这些操作,但是我找不到任何允许这样做的分析提供程序.

I want to use something like Phonegap to write an app for Android, iOS and Blackberry, as well as generate free analytics data such as session length and how often buttons are pressed. I'd like to be able to do all this in JavaScript if possible but I cannot find any analytics provider that allows this.

我唯一看到的选择是使用支持所有这些OS的Flurry.这将需要每个平台一些本机代码,以及从JavaScript调用此代码的方法.如果可能的话,我宁愿不必编写本机代码.

The only option I can see is to use Flurry which supports all those OSs. This would require some native code for each platform and a way to call this code from JavaScript. I'd rather avoid having to write native code if possible.

我尝试使用网络版Google Analytics(例如,将JavaScript代码段添加到我的应用代码中),但这会导致记录错误

I tried using the web version of Google Analytics (e.g. adding JavaScript snippets to my app code) but this produces the logging error

http://www.google-analytics.com/u/ga_debug.js: Line 18 : Local file. Aborting hit.

我认为这意味着Google Analytics(分析)仅适用于实际的网页. Google Apps的Google Analytics(分析)也不适用于Blackberry.

which I assume means Google Analytics only works on actual web pages. Google Analytics for apps isn't available for Blackberry either.

推荐答案

您可以将您的应用程序与Flurry HTML 5 SDK集成在一起.这样,您可以使用JavaScript编写HTML 5应用程序.完成后,您可以将其移植到本机平台.请注意,Flurry HTML 5 SDK目前处于测试版,一旦在Flurry上注册,便可以启用. (完全公开:我在Flurry的支持团队工作)

You can integrate your apps with Flurry HTML 5 SDK. This way you can write HTML 5 apps using JavaScript. Once done, you can port it to the native platform. Please note that Flurry HTML 5 SDK is currently in beta, and can be enabled for you once you register on Flurry. (Full disclosure: I work in the Support team at Flurry)

这篇关于基于跨平台JavaScript的移动应用程序的分析的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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