ITunes审核URL和iOS 7(要求用户评价我们的应用程序)AppStore显示空白页面

Sam*_*uel 158 iphone itunes rating app-store ios7

有谁知道用于要求用户评价我们的应用程序并直接在评级页面上为他打开​​App Store的技术是否仍在iOS 7上运行?

我曾经从我的应用程序打开这个网址:

itms-apps://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?id=353372460&onlyLatestVersion=true&pageNumber=0&sortOrdering=1&type=Purple+Software
Run Code Online (Sandbox Code Playgroud)

但看起来它不再起作用了(AppStore显示空白页面).我也试过这个网址,但没有运气:

http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?pageNumber=0&sortOrdering=1&type=Purple+Software&mt=8&id=353372460
Run Code Online (Sandbox Code Playgroud)

Fra*_*ank 198

从iOS7开始,URL已更改,无法指向审阅页面,只能指向应用程序

itms-apps://itunes.apple.com/app/idAPP_ID
Run Code Online (Sandbox Code Playgroud)

APP_ID需要替换为您的应用程序ID.根据问题中的App ID,它将如下所示

itms-apps://itunes.apple.com/app/id353372460
Run Code Online (Sandbox Code Playgroud)

注意数字前面的id ...该字符串是id 353372460,而不仅仅是353372460

对于iOS7之前的任何内容,需要使用"旧"URL,只有那些可以直接进入评论页面.您还应注意,这些调用仅适用于设备.由于模拟器没有安装App Store应用程序,因此在模拟器中运行它们将无效.


请查看Appirater实例.https://github.com/arashpayan/appirater

无法帮助您使用phonegap细节(从未使用过它).但它基本上归结为检查用户正在运行的iOS版本,然后使用旧URL或新的iOS7 URL.

  • 实际上这会打开应用程序,而不是审阅选项卡. (18认同)
  • 你想要删除语言,如果设备设置为不等于iTunes商店的语言你得到一个空白页面(例如英国英语),Appirater也有同样的问题,如果你删除语言位它仍然有效并且商店打开在业主语言. (6认同)
  • 是的,这是真的,但在iOS7下,目前这是目前可以实现的最佳目标. (3认同)
  • 谢谢,弗兰克.StoreKit可以满足我的需求. (2认同)

mkl*_*kll 166

以下URL在iOS 7.1上完美运行:

http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?id=xxxxxxxx&pageNumber=0&sortOrdering=2&type=Purple+Software&mt=8
Run Code Online (Sandbox Code Playgroud)

xxxxxxxx是您的应用ID.

更新.适用于iOS 9.3.4和iOS 10 GM(由Jeet提供)

  • 这应该是接受的答案,适用于iOS7.1 (10认同)
  • 我发现.类型应该始终等于紫色软件 - 它是一个苹果的东西. (7认同)
  • 适合我直接进入App Store.app审查页面.使用Xcode构建6.在iOS 8.0,iOS 7.1.2,iPhone 5和iPhone 4中验证. (6认同)
  • 这在8.0 DP 5中又被打破了!现在报告它是一个错误,希望我们可以通过生产版本来修复它. (5认同)
  • 仍然正常,iOS 8.1,Xcode 6 (4认同)
  • 它适用于iOS 8.3中的iPhone和iPad.刚刚测试过:)谢谢! (2认同)
  • 适用于iPod Gen 5,iOS 9.0.1. (2认同)
  • 在iPhone 5s,iOS 9.1上完美运行谢谢! (2认同)
  • 我可以确认这也适用于iOS 10 Golden Master. (2认同)

Ida*_*dan 47

这适用于我(Xcode 5 - iOS 7 - 设备!):

itms-apps://itunes.apple.com/app/idYOUR_APP_ID
Run Code Online (Sandbox Code Playgroud)

对于低于iOS 7的版本,请使用旧版本:

itms-apps://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?type=Purple+Software&id=YOUR_APP_ID
Run Code Online (Sandbox Code Playgroud)

  • 我使用以下代码`[[UIApplication sharedApplication] openURL:[NSURL URLWithString:ITUNES_APP_URL_IOS7]];` (2认同)

Jas*_*lla 18

单行代码简单替代方案: **另见下面的模拟器评论**

http://itunes.apple.com/app/idAPP_ID

编辑:既然iOS 7.1允许直接链接到App Store中的评论标签,那么值得投入额外的代码行直接到达那里:其余的请参见其他答案.

这里我们使用的是 http: 代替 itms-apps:,让iOS完成剩下的工作

我在iOS 6.1和7设备(iPad/iPhone/iPod touch 4)上获得了相同的结果测试.

具体来说,这个用于iOS 6的快捷方式将用户带到选项卡而不是选项卡.DetailsReviews

Purple+Software链接将用户一直带到iOS 6中的"评论"选项卡,如果您知道如何检查操作系统,这显然是首选.

重要说明:这将导致iOS 5.1,6.1和7模拟器出错.
无法打开页面Safari无法打开页面,因为地址无效(我们知道它是模拟器外的任何浏览器上的有效URL)

需要明确的是:在iOS 7上:http://提供相同的体验itms-apps:,没有明显的延迟.

*请记住上面提到的模拟器行为.这与尝试通过模拟器访问摄像机并不完全不同:模拟器不是测试它的地方.*


Mur*_*ali 17

可以在iOS7中直接从应用程序打开评论页面.请使用以下网址...

itms-apps://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?type=Purple+Software&id=YOUR_APP_ID
Run Code Online (Sandbox Code Playgroud)

这肯定会有效.. :)


Jos*_*ffy 16

目前尚不清楚支持哪种版本的iOS,但作为iOS 10.3的一部分,有一个新的查询参数可以添加到URL中:action=write-review.我已经在iOS 10.2和9.3.5上测试了这个并且它可以工作.但是,它在iOS 7.1.2上不起作用,因此在iOS 8.0和9.3.5之间添加了支持.需要进一步调查!

示例:https://itunes.apple.com/app/id929726748?action = write-review&mt = 8

这将打开"撰写评论"对话框,而不是仅显示评论标签.

  • 干杯兄:)这是迄今为止最好的解决方案.至关重要,完全达到目的.对我来说,这是可以接受的答案.经过测试,可以使用9.3.5和iOS 10.2.1.直接打开写评论.我用过这个:itms-apps://itunes.apple.com/gb/app/id1136613532?action = write-review&mt = 8,让用户直接写评论. (2认同)

Wil*_*ill 9

+ (NSString *)getReviewUrlByAppId:(int)appId
{ 
    NSString *templateReviewURL = @"itms-apps://ax.itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?type=Purple+Software&id=APP_ID";
    NSString *templateReviewURLiOS7 = @"itms-apps://itunes.apple.com/app/idAPP_ID";
    NSString *templateReviewURLiOS8 = @"itms-apps://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?id=APP_ID&onlyLatestVersion=true&pageNumber=0&sortOrdering=1&type=Purple+Software";

    //ios7 before
    NSString *reviewURL = [templateReviewURL stringByReplacingOccurrencesOfString:@"APP_ID" withString:[NSString stringWithFormat:@"%d", appId]];

    // iOS 7 needs a different templateReviewURL @see https://github.com/arashpayan/appirater/issues/131
    if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0 && [[[UIDevice currentDevice] systemVersion] floatValue] < 7.1) 
    {
        reviewURL = [templateReviewURLiOS7 stringByReplacingOccurrencesOfString:@"APP_ID" withString:[NSString stringWithFormat:@"%d", appId]];
    }
    // iOS 8 needs a different templateReviewURL also @see https://github.com/arashpayan/appirater/issues/182
    else if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 8.0)
    {
        reviewURL = [templateReviewURLiOS8 stringByReplacingOccurrencesOfString:@"APP_ID" withString:[NSString stringWithFormat:@"%d", appId]];
    }

    return reviewURL;
}
Run Code Online (Sandbox Code Playgroud)


Ser*_*nce 9

iOS9中的评论链接再次破裂.在进行一些实验时,我发现Apple将其恢复到iOS7之前的状态.所以你必须这样做:

itms-apps://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?id=247423477&onlyLatestVersion=true&pageNumber=0&sortOrdering=1&type=Purple+Software
Run Code Online (Sandbox Code Playgroud)

247423477您的9位数应用ID 在哪里(主要区别在于您必须&onlyLatestVersion=true&pageNumber=0&sortOrdering=1&type=Purple+Software在应用ID之后追加).


Han*_*son 5

上面的所有答案现已被弃用(iOS 7,但可能有效),因此,我提供Apple建议提供应用程序链接的新方式.您的应用程序的链接是iTunes中的链接(使用复制链接),建议在代码中使用此链接:

Swift 3.0

let path = URL(string: "https://itunes.apple.com/us/app/calcfast/id876781417?mt=8")
UIApplication.shared.open(path!)
Run Code Online (Sandbox Code Playgroud)

或者更好 - 正确对待可选项并处理无法访问链接的可能性:

if let path = URL(string: "https://itunes.apple.com/us/app/calcfast/id876781417?mt=8") {
    UIApplication.shared.open(path) {
        (didOpen:Bool) in
        if !didOpen {
            print("Error opening:\(path.absoluteString)")
        }
    }
}
Run Code Online (Sandbox Code Playgroud)

Objective-C的

#define APP_URL_STRING  @"https://itunes.apple.com/us/app/calcfast/id876781417?mt=8"
Run Code Online (Sandbox Code Playgroud)

然后你可以调用APP_URL_STRING你的代码:

[[UIApplication sharedApplication] openURL:[NSURL URLWithString: APP_URL_STRING] options:@{} completionHandler:nil];
Run Code Online (Sandbox Code Playgroud)

请注意,这是Apple现在推荐的方式,因为之前处理重定向链接的方法已被弃用且不受支持.

所有应用的链接,如果您有多个应用:

#define MYCOMPANY_URL_PATH @"http://appstore.com/mycompany"
[[UIApplication sharedApplication] openURL:[NSURL URLWithString: MYCOMPANY_URL_PATH] options:@{} completionHandler:nil];
Run Code Online (Sandbox Code Playgroud)

建议将上面的App链接用于代码或用户未直接看到的链接.如果您想提供用户可以看到和记住的链接,请使用以下内容: http://appstore.com/calcfast

  • 这不会链接到评论页面 (3认同)