应用程序内的iOS应用程序更新检查 [英] IOS app update check within application

查看:166
本文介绍了应用程序内的iOS应用程序更新检查的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要在应用程序内的Apple Store中检查应用程序更新. 每次启动应用程序时,我们都需要检查一下.

I need to check application updation in apple store within the application. Every time application starting we need to check this..

请在下面的帖子中查看答案: iOS应用更新通知

please check answer in below post: iOS app update notification

哪个是最好的选择? Harpy或其他任何东西?

which one is best option? Harpy or any other?

推荐答案

您需要在服务器上启动应用程序在启动时要求的WebService(或类似功能),以了解哪个是最新版本. (如果您还没有WS,并且真的不想为此实现WS,则也可以只使用也包含该版本的XML或文本文件)

You need to have a WebService on your server (or something similar) that your app requests at startup, to know which is the latest version available. (If you don't have a WS yet and really don't want to implement one for that, you may also simply use an XML or text file that contains the version too)

然后使用[[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleVersion"].

如果它们不同,则可以显示警报视图并重定向到itms- apps://phobos.apple.com/WebObjects/MZStore.woa/wa/viewSoftwareUpdate?id=[APPID]&mt=8(将iTunes的AppID替换为iTunes的App ID),该链接将使您的iPhone在应用程序更新时直接打开AppStore应用程序页面.

If they are different, you can display the alertview and redirect to itms-apps://phobos.apple.com/WebObjects/MZStore.woa/wa/viewSoftwareUpdate?id=[APPID]&mt=8 (replacing APPID with your iTunes Connect App ID), which is the link that will make your iPhone open the AppStore application directly on your application's update page.

您也可以使用,但是如果您从应用商店中抓取您总是有更新应用程序商店的风险,并且您的应用程序将无法获取最新版本,因此您必须像上一步一样进行自己的版本检查.

You can go with this too but if you Scrape from the app store you're always at risk of having the app store updated and your apps won't be able to fetch the latest version, so you must go with your own version checks like upper steps.

这篇关于应用程序内的iOS应用程序更新检查的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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