iPhone报亭推送注册失败 [英] iPhone Newsstand push registration Failure

查看:15
本文介绍了iPhone报亭推送注册失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

//注册通知

[[UIApplication sharedApplication]
 registerForRemoteNotificationTypes:(
                                     UIRemoteNotificationTypeAlert |
                                     UIRemoteNotificationTypeBadge |
                                     UIRemoteNotificationTypeSound |
                                     UIRemoteNotificationTypeNewsstandContentAvailability)];

这是我用来注册推送通知的代码.该应用程序注册警报、徽章、声音.但是该应用程序没有注册报摊推送通知.检查它

This is the code I use for registering for registering for push notifications. The app registers for Alert, Badges, Sound. But the app did not register for the newsstand push notifications. Checked it in

didRegisterForRemoteNotificationsWithDeviceToken

方法,有这个条件

if([application enabledRemoteNotificationTypes] & UIRemoteNotificationTypeNewsstandContentAvailability)

这段代码可能有什么问题.

What might the issue with this code.

推荐答案

推送通知在 iPhone 模拟器上不起作用,因此请尝试在设备上运行它.

Push notifications don't work on iPhone Simulator, so try to run it on a device.

如果这没有帮助,请尝试:

If this doesn't help, try to:

  • 实现应用程序:didFailToRegisterForRemoteNotificationsWithError:方法委托并检查错误描述
  • 检查此应用 ID 的推送设置并重新生成配置文件
  • 检查 aps-环境

这篇关于iPhone报亭推送注册失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆