跳转到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. 2016.8.22 Axure两级下拉框联动的实现

    刚学Axure,有些很简单的东西都要弄很久,但是弄出来的总归是很开心的. 参考来自:实现省市县下拉框的三级联动 http://www.woshipm.com/rp/348795.html/commen ...

  2. DevExpress控件之LookupEdit,ComboBoxEdit

    ComboBoxEdit 1.  ComBoxEdit没有DisplayMember  和  ValueMember 属性,只能获取显示的值2.当前选定值comboBoxEdit1.Propertie ...

  3. 自主研发异步通信框架Minma(支持长连接和短连接)

    Minma是英文Minma Is Not Mina的简称 该框架采用Java NIO的核心技术,实现了基于事件驱动的多线程异步通信框架,支持常见的长连接(腾讯QQ)和短连接(http通信) 对于开发人 ...

  4. ZT:成熟是一种明亮而不刺眼的光辉

    成熟是一种明亮而不刺眼的光辉, 一种圆润而不腻耳的音响, 一种不再需要对别人察言观色的, 一种终于停止向周围申诉求告的大气, 一种不理会哄闹的微笑, 一种洗刷了偏激的冷漠, 一种无需声张的厚实, 一种 ...

  5. 用递归法将一个整数n转换成字符串。

    用递归法将一个整数n转换成字符串. 比如,输入483,应输出字符串"483".n的位数不确定,能够是随意位数的整数. #include "stdafx.h" # ...

  6. js 组合键监听ctrl + enter

    $(window).keydown(function (event) { // 监听esc键退出全屏 if (event.keyCode == 27) { } // 监听 Ctrl + Enter 可 ...

  7. 在Mac OS X中下载Android源代码的一些经验

    首先说明.随着最近(2014年6月開始)GFW的升级.这个站点:http://www.android.com/ 已经不能正常訪问了,以下的这些操作均是在我连接VPN的时候进行的. 首先,须要做一些准备 ...

  8. 想全面理解JWT?一文足矣!

    有篇关于JWT的文章,叫"JWT: The Complete Guide to JSON Web Tokens",写得全面细致.为了自己能更清晰理解并惠及更多人,我把它大致翻译了过 ...

  9. 根据URL发起HTTP请求,我的HTTPHelper。

     完整的demo using System; using System.Collections.Generic; using System.Linq; using System.Text; using ...

  10. Mysql 5.7.18 加密连接mysql_ssl_rsa_setup

    MySQL 5.7.18 下载地址: https://dev.mysql.com/get/Downloads/MySQL-5.7/mysql-5.7.18-linux-glibc2.5-x86_64. ...