clarity
clarity

Reputation: 431

redirect iphone app to apple store

I have an iphone app, and when there are upgrades available, I want to prompt the user to upgrade, and if they click upgrade, I want to redirect them to the apple store. How is this done?

Thanks

Upvotes: 7

Views: 3906

Answers (3)

joshpaul
joshpaul

Reputation: 953

You'll either want to use a Push notification, or have your app check somewhere online (that you can update) so when an update is available you can present an alert. Then, upon an OK from the user, simply send 'em to your app in the store using the itunes URL.

Upvotes: -1

Jeff B
Jeff B

Reputation: 30099

Apple documents the process here: http://developer.apple.com/library/ios/#qa/qa2008/qa1629.html

The basics boils down to using an NSURL to open an iTunes link:

NSString *iTunesLink = @"http://itunes.apple.com/us/app/warehouse51/id364201184?mt=8";

[[UIApplication sharedApplication] openURL:[NSURL URLWithString:iTunesLink]];

However, I don't believe there is a way to direct to the upgrade tab.

Note: phobos links are generally outdated, so ignore that your link won't look like the example in Apple's doc. It will generally look like the one in my updated example here.

Upvotes: 12

Eiko
Eiko

Reputation: 25632

Just open the appropriate iTunes URL for your application. Users will have to go to the update tab on their own, though.

Upvotes: 0

Related Questions