iOS8注册推送
2014-10-24 15:36
225 查看
Apple在9月18日正式发布了iOS8,在收到更新的同时,也发现自己的应用在iOS8下无法启动。
并且在Console中收到如下提示:
解决方案:需兼容iOS7和iOS8的注册推送
并且在Console中收到如下提示:
registerForRemoteNotificationTypes: is not supported in iOS
8.0
and later.
解决方案:需兼容iOS7和iOS8的注册推送
if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 8.0) { [[UIApplication sharedApplication] registerUserNotificationSettings:[UIUserNotificationSettings settingsForTypes:(UIUserNotificationTypeSound | UIUserNotificationTypeAlert | UIUserNotificationTypeBadge) categories:nil]]; [[UIApplication sharedApplication] registerForRemoteNotifications]; } else { [[UIApplication sharedApplication]registerForRemoteNotificationTypes:(UIRemoteNotificationTypeAlert|UIRemoteNotificationTypeSound|UIRemoteNotificationTypeBadge)]; }
相关文章推荐
- 【IOS】IOS8推送消息注册 通知
- IOS开发之 ---- IOS8推送消息注册
- IOS8注册推送消息
- iOS8 注册推送
- iOS8 推送注册方式改变的问题
- iOS8注册推送失败的探究
- ios7与ios8并存,注册推送通知
- iOS8之后的远程推送注册代码
- ios8 远程推送的注册代码
- 【IOS】ios8推送消息注册
- 【IOS】ios8推送消息注册
- iOS8推送消息、注册通知
- ios8注册推送通知
- ios8 注册本地推送通知
- IOS开发之 ---- IOS8推送消息注册
- iOS开发----iOS8 注册推送
- iOS8 推送注册方式改变的问题
- Android开发-个推(getui)透传推送实战项目应用(一)个推注册与官方Demo
- IOS 推送机制详解,兼容IOS8的推送
- C# 服务端推送,十步十分钟,从注册到推送成功