【问题标题】:Rate and review within an app possible in iOS7?在 iOS7 中是否可以在应用内评分和评论?
【发布时间】:2013-11-04 06:54:57
【问题描述】:

我听说 iOS7 允许用户在该应用程序内对应用程序进行评分和评论,从而避免重定向到应用程序商店和离开应用程序的需要。到目前为止,我只发现了ITunes review URL and iOS 7 (ask user to rate our app) AppStore show a blank page中提到的itunes中rate功能的URL链接的区别,但没有发现如何留在应用程序中。

我在我的应用程序中使用 Appirater 并集成了新的 url,应用程序转到 appstore 进行评分/审查。

谁能告诉我这个新功能是否存在以及如何实现它?

【问题讨论】:

    标签: ios appirater


    【解决方案1】:

    我在使用 Appirater 时遇到了同样的问题,我已经通过这种方式部分解决了问题

    为iOS7定义模板:

    NSString *templateReviewURLiOS7 = @"itms-apps://itunes.apple.com/app/idAPP_ID";

    改变 rateApp 方法

    + (void)rateApp {
    
        .
        .
        .
    
    // this URL Scheme should work in the iOS 6 App Store in addition to older stores
    NSString *reviewURL = [templateReviewURL stringByReplacingOccurrencesOfString:@"APP_ID" withString:[NSString stringWithFormat:@"%@", _appId]];
    
       // iOS 7 needs a different templateReviewURL @see https://github.com/arashpayan/appirater/issues/131
       if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0) {
           reviewURL = [templateReviewURLiOS7 stringByReplacingOccurrencesOfString:@"APP_ID" withString:[NSString stringWithFormat:@"%@", _appId]];
       }
    
        .
        .
        .
    }
    

    这将像过去一样在 iOS6 中打开费率页面,在 iOS7 中打开应用页面

    【讨论】:

    • 我也这样做了,但这又把我从我的应用程序带到了应用商店。
    【解决方案2】:

    我认为您正在寻找 SKProductViewController。

    您可以使用以下代码显示 SKProductViewController:

    NSDictionary *parameters = [NSDictionary dictionaryWithObject:@"YOURITUNESAPPID" forKey:SKStoreProductParameterITunesItemIdentifier];
    
    SKProductViewController *productViewController = [[SKProductViewController alloc] init];
    [self presentViewController:productViewController animated:YES completion:nil]];
    

    这假设您在 UIViewController 子类中并且知道您的 iTunes 应用程序标识符。这将显示一个模型 viewController 显示该应用程序的 AppStore 条目。

    用户可以从该 viewController 留下评分。虽然无法写评论。

    【讨论】:

    • 工作就像一个魅力。谢谢!!
    • 这不起作用,Apple 已禁用在 iOS 7 中使用 SKProductViewController 审查应用程序的可能性。
    • 您的示例中没有使用parameters 变量
    • @mattsson 你是对的,我只是不幸地发现“写评论”按钮没有启用。如果启用它会很棒:(
    猜你喜欢
    • 2016-12-23
    • 1970-01-01
    • 2022-11-30
    • 2020-04-19
    • 2020-10-31
    • 2017-08-08
    • 2013-02-09
    • 2012-04-17
    • 1970-01-01
    相关资源
    最近更新 更多