黄舟2017-04-17 11:23:02
For example, the webpage URL of an app is: https://itunes.apple.com/cn/app/xue-qiu-gu-piao-tou-zi-she-qu/id492180369?mt=8&uo=4
Then the native url is to change the protocol https
to itms-apps
. Open the replaced url in your app to jump to the app store. You can find the app url here: http://itunes. apple.com/linkmaker
Open app store modally
You can use SKStoreProductViewController:
NSDictionary *appParameters = [NSDictionary dictionaryWithObject:@"533886215" forKey:SKStoreProductParameterITunesItemIdentifier]; SKStoreProductViewController *productViewController = [[SKStoreProductViewController alloc] init]; [productViewController setDelegate:self]; [productViewController loadProductWithParameters:appParameters completionBlock:^(BOOL result, NSError *error) { }]; [self presentViewController:productViewController animated:YES completion:^{ }];