跳转到AppStore让用户能够给我们的应用进行评分,有两种方法,一种是跳出应用,跳转到AppStore,进行评分.另一种是在应用内,内置AppStore进行评分.

PS:appleID在https://itunesconnect.apple.com中创建应用即可在应用界面获得

1.跳出应用,跳转到AppStore,进行评分

如果是7.0以前的系统

NSString *str = [NSString stringWithFormat:@"itms-apps://ax.itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?type=Purple+Software&id=xxxxxx" ];

[[UIapplication sharedApplication] openURL:[NSURL URLWithString:str]];

如果是7.0以后的系统

NSString *str = [NSString stringWithFormat:@"itms-apps://itunes.apple.com/app/idxxxxxxx"];

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

2.在应用内,内置AppStore进行评分

苹果提供了一个框架StoreKit.framework,导入StoreKit.framework,在需要跳转的控制器里面添加头文件 #import <StoreKit/StoreKit.h>, 实现代理方法:< SKStorePRoductViewControllerDelegate >

//自定义方法

- (void)loadAppStoreController

{

// 初始化控制器

SKStoreProductViewController *storeProductViewContorller = [[SKStoreProductViewController alloc] init];

// 设置代理请求为当前控制器本身

storeProductViewContorller.delegate = self;

[storeProductViewContorller loadProductWithParameters:@{SKStoreProductParameterITunesItemIdentifier:kAppId}  completionBlock:^(BOOL result, NSError *error)   {

if(error)

{

NSLog(@"error %@ with userInfo %@",error,[error userInfo]);

}  else

{

// 模态弹出appstore

[self presentViewController:storeProductViewContorller animated:YES completion:^{

}];

}

}];

}

//AppStore取消按钮监听

- (void)productViewControllerDidFinish:(SKStoreProductViewController *)viewController

{

[self dismissViewControllerAnimated:YES completion:^{

}];

}

跳转appStore评分的更多相关文章

  1. iRate---一个跳转AppStore评分弹窗

    https://www.aliyun.com/jiaocheng/357479.html 摘要:gitHub地址:https://github.com/nicklockwood/iRate可以通过配置 ...

  2. 47.iOS跳转AppStore评分和发送邮件

    1.跳转到AppStore评分 应用地址是关键:IOS 设备,手机搜索应用,拷贝链接 NSString *appStr =@"https://itunes.apple.com/cn/app/ ...

  3. 跳转AppStore 评分

    -(void)goToAppStore { NSString *str = [NSString stringWithFormat: @"itms-apps://ax.itunes.apple ...

  4. ios------app跳转到appStore评分

    跳转到AppStore评分,有两种方法: 一种是跳出应用,跳转到AppStore,进行评分: 另一种是在应用内,内置AppStore进行评分. PS:appID在https://itunesconne ...

  5. App 打包并跳过 AppStore 的发布下载

    一.App 打包 (编译 -> 链接 -> 打包) 1) 下载发布版的证书并安装. 2)Target -> Build Setting,改为发布版本的 profile 3) Targ ...

  6. iOS7跳转AppStore地址

    跳转AppStore地址改变: 由 itms-apps://ax.itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews? ...

  7. IOS6.0 应用内直接下载程序 不需跳转AppStore -b

    闲来没事看了篇文章 应用内创建应用商店环境,不跳转AppStore. 先武断的想一句:放屁.然后好奇的进去看看,原来是IOS6.0的新特性,顿感惭愧.研究下 SKStoreProductViewCon ...

  8. 如何从应用直接跳转AppStore 电话 短信 邮件

    //如何从应用直接跳转AppStore [[UIApplication sharedApplication]openURL:[NSURL URLWithString:@"应用程序的下载链接& ...

  9. 微信无法跳转appstore总结--应用宝微下载申请

    以前是有方法,可以实现微信下跳转appstore的. 大概就是把url改为:http://mp.weixin.qq.com/mp/redirect?url="跳转url"(可编码也 ...

随机推荐

  1. Android - EditText 注意(缺少字符)

    EditText 注意(缺少字符) 本文地址:http://blog.csdn.net/caroline_wendy EditText使用监听(Listener)addTextChangedListe ...

  2. CentOS-7 在windows server 2012下的虚拟机安装教程

    CentOS-7 在windows server 2012下的虚拟机安装教程 一.下载 CentOS-7-x86_64-DVD-1611.iso https://mirrors.aliyun.com/ ...

  3. Git 学习之--安装配置GitHub

    楼主今天学习了一下Git的使用,而且Androdi studio 下加入了Git插件,成功提交项目到自己Github个人主页 watermark/2/text/aHR0cDovL2Jsb2cuY3Nk ...

  4. 关于 html 中 table 表格 tr,td 的高度和宽度

    http://wenku.baidu.com/link?url=76BZcBS3YyA1QJwE7pCPJKERPex4uSQEQ1LI5ZkwTCtunw2cBTaLI8E71dxUhFW0CH4h ...

  5. 阿里云官方教程 Linux 系统挂载数据盘

    适用系统:Linux(Redhat , CentOS,Debian,Ubuntu) *  Linux的云服务器数据盘未做分区和格式化,可以根据以下步骤进行分区以及格式化操作. 下面的操作将会把数据盘划 ...

  6. ubuntu在terminal下安装mysql

    安装的时候.仅仅须要在terminal中输入下面几条命令 1.sudo apt-get install mysql-server 2.apt-get isntall mysql-client 3. s ...

  7. Java中的线程池ExecutorService

    示例 import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.u ...

  8. 华为p20:拍美景,听讲解,旅行更智能

    华为P20轰轰烈烈地上市了,本来对手机并不感冒的我,看到身边的好友换了P20,不禁感慨:这个月的活又要白干了,全部都要上交给华为,因为这款手机完全戳中了旅游爱好者的痛点. 痛点一:丢弃笨重的单反,手机 ...

  9. zabbix 3.2.4 安装

    一.安装mysql . 安装必备组件 yum install –y autoconf automake imake libxml2-devel expat-devel cmake gcc gcc-c+ ...

  10. 查看SELinux状态并关闭SELinux

    SELinux(Security-Enhanced Linux)是Linux上最杰出的新安全子系统.在linux内核级别上提供了一个灵活的强制访问控制系统(MAC),这个强制访问控制系统是建立在自由访 ...