1.找到应用程序的叙述原文链接,实例:

https://57324.api-01.com/serve?

action=click&publisher_id=57324&site_id=48830

2.然后将 http:// 替换为 itms:// 或者 itms-apps://
,例如以下:

itms://57324.api-01.com/serve?

action=click&publisher_id=57324&site_id=48830

itms-apps://57324.api-01.com/serve?action=click&publisher_id=57324&site_id=48830

3.关联方法。在方法中调用以下方法

<span style="font-size:18px;">[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"itms:
//57324.api-01.com/serve?action=click&publisher_id=57324&site_id=48830"]];</span>
<span style="font-size:18px;">[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"itms-apps:
//57324.api-01.com/serve?action=click&publisher_id=57324&site_id=48830"]];</span>

版权声明:本文博主原创文章。博客,未经同意不得转载。

04-20 10:33