简体   繁体   English

在Flurry SDK的帮助下跟踪页面浏览量?

[英]Tracking Page views with the help of Flurry SDK?

I have integrated mobile analytics in my iPhone app with the help of the Flurry analytics but I am not able to track page views. 我已经在Flurry分析的帮助下将移动分析集成到了我的iPhone应用程序中,但是我无法跟踪页面浏览量。

I have used the following code in my Application Delegate and passed an instance of UINavigationController in the place of navigationController 我在应用程序委托中使用了以下代码,并在NavigationController处传递了UINavigationController的实例
[FlurryAPI logAllPageViews:navigationController];

But while checking the Page views in the Flurry website it is showing the message like this: 但是,在Flurry网站上查看“网页浏览量”时,它会显示如下消息:

You are not currently tracking Page View data. 您当前不在跟踪“页面浏览”数据。

Is there something that I have to enable in the flurry website itself? 我必须在flurry网站本身中启用什么功能?

Good that you now see your data. 好了,您现在可以看到自己的数据。

On the page count: Flurry Analytics SDK just counts the number of page views. 在页面数上:Flurry Analytics SDK仅计算页面浏览量。 If you want to see what pages in your app the user visits, i suggest creating events for each of your screens. 如果要查看用户访问应用程序中的哪些页面,建议您为每个屏幕创建事件。 The user paths report in the events section of your dashboard will then give you a clear path of how your users move around in your app. 然后,信息中心的“事件”部分中的“用户路径”报告将为您提供清晰的路径,说明您的用户如何在应用程序中四处移动。

"logAllPageViews" method increments the page view count for a session based on traversing a UINavigationController or UITabBarController. “ logAllPageViews”方法基于遍历UINavigationController或UITabBarController来增加会话的页面浏览量。 If you want to track screens with screen name then just use logEvent method of FlurryAnalytics class like 如果要跟踪具有屏幕名称的屏幕,则只需使用FlurryAnalytics类的logEvent方法,例如

[FlurryAnalytics logEvent:@"screen name"]; [FlurryAnalytics logEvent:@“屏幕名称”];

source (check for logAllPageVeiws and logPageView): http://support.flurry.com/sdkdocs/iOS/interface_flurry_analytics.html#adb7d3bd888a40343269c53f65acf7720 源(检查logAllPageVeiws和logPageView): http : //support.flurry.com/sdkdocs/iOS/interface_flurry_analytics.html#adb7d3bd888a40343269c53f65acf7720

The other benefit of using events is that they are logged within minutes , showing up in the event logs of Flurry well before being accumulated into the summaries. 使用事件的另一个好处是它们可以在几分钟内记录下来 ,并在累积到摘要之前很好地显示在Flurry的事件日志中。 This fast turnaround might prove vital to debugging, as described below. 如下所述,这种快速的周转可能对于调试至关重要。

Note one other gotcha if you fail to see anything, in the case of using iOS I was running many tests and not even events were showing up. 如果您看不到任何东西,请注意另一个陷阱,在使用iOS的情况下,我正在运行许多测试,甚至没有出现任何事件。

It turned out the code was initialising with 原来代码正在初始化

[Flurry setSessionSReportsOnPauseEnabled:NO];
[Flurry setSessionSReportsOnCloseEnabled:NO];

These supposedly buffer your flurry details until the start of the next session. 据说这些缓冲您的紧急信息,直到下一个会话开始为止。 However, some side-effect of debugging meant that the buffering wasn't preserved so my events were never being despatched. 但是,调试的一些副作用意味着未保留缓冲,因此从未调度我的事件。

(I inherited a large codebase recently so am still being surprised by things like this.) (我最近继承了一个大型代码库,因此仍然对这样的事情感到惊讶。)

If this question is still open or relevant, you may want to make sure you are adding the navigationController that is in charge of your navigation. 如果此问题仍然悬而未决或相关,那么您可能需要确保添加了负责导航的navigationController。 Try posting some code with your questions will provide better answers. 尝试发布一些带有问题的代码将提供更好的答案。

It also takes a little bit of time to see results posted to Flurry. 将结果发布到Flurry还需要一点时间。

You may also use Localytics for this purpose: http://www.localytics.com unlike the other services mentioned you will see your results immediately so you can integrate, test and be done with this process in less than 10 minutes. 您也可以将Localytics用于此目的: http : //www.localytics.com与上面提到的其他服务不同,您将立即看到结果,因此您可以在不到10分钟的时间内集成,测试并完成此过程。

The easiest way to track page views with Localytics is to tag an event, when each page is loaded. 使用Localytics跟踪页面浏览量的最简单方法是在加载每个页面时标记一个事件。 You can do that with a single API call (modified version of the example in the docs: http://wiki.localytics.com/doku.php?id=iphone_ios4_integration ) To track a page the code is: [[LocalyticsSession sharedLocalyticsSession] tagEvent:@"Start Page"]; 您可以通过单个API调用(文档中示例的修改版本: http ://wiki.localytics.com/doku.php?id=iphone_ios4_integration)来做到这一点要跟踪页面,代码是:[[LocalyticsSession sharedLocalyticsSession] tagEvent:@“起始页”];

Another clever thing you should do is, add an event in your applicationWillEnterBackground which tags an 'app exit' event which records what screen the user was on: NSDictionary *dictionary = [NSDictionary dictionaryWithObjectsAndKeys: @"exit screen", current_screen_name, nil]; 您应该做的另一件聪明的事情是,在applicationWillEnterBackground中添加一个事件,该事件标记一个“应用程序退出”事件,该事件记录用户所在的屏幕:NSDictionary * dictionary = [NSDictionary dictionaryWithObjectsAndKeys:@“退出屏幕”,current_screen_name,nil]; [[LocalyticsSession sharedLocalyticsSession] tagEvent:@"Leaving App", attributes:dictionary]; [[LocalyticsSession sharedLocalyticsSession] tagEvent:@“ Leave App”,attributes:dictionary];

This way you can quickly see a distribution of your most common exit pages. 这样,您可以快速查看最常见的退出页面的分布。

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM