//注册通知
[[UIApplication sharedApplication]
registerForRemoteNotificationTypes:(
UIRemoteNotificationTypeAlert |
UIRemoteNotificationTypeBadge |
UIRemoteNotificationTypeSound |
UIRemoteNotificationTypeNewsstandContentAvailability)];
这是我用于注册推送通知的代码。该应用程序注册警报,徽章,声音。但该应用程序没有注册报摊推送通知。检查了
didRegisterForRemoteNotificationsWithDeviceToken
方法,具有此条件
if([application enabledRemoteNotificationTypes] & UIRemoteNotificationTypeNewsstandContentAvailability)
此代码可能存在什么问题。
答案 0 :(得分:0)
您是否已包含Newsstand Info.plist密钥?您可以检查为报亭注册的应用是否会推送设置/存储。
答案 1 :(得分:0)
推送通知在iPhone模拟器上不起作用,因此请尝试在设备上运行。
如果这没有帮助,请尝试: