没有声音在iOS8上解析推送通知 [英] No sound in Parse push notification for ios8

查看:194
本文介绍了没有声音在iOS8上解析推送通知的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在与推送通知到iOS8上设备的问题。一切工作正常,但推不振铃,只出现在屏幕上。
我通过仪表盘发送正常的推,在这种声音是默认启用。我的iPhone4上(的iOS 7.1.2),iPhone5的(的iOS 7.0.4)进行测试,它工作正常,但在iPhone上没有声音与iOS 8。
谢谢

I'm having as issue with Push Notification to iOS8 device. Everything works fine, but the push is not ringing, only appears on the screen. I am sending normal pushes via dashboard, in which sound is enabled by default. I tested on iPhone4 (iOS 7.1.2), iPhone5 (iOS 7.0.4), it works fine, but there is no sound on iPhone with iOS 8. Thanks

编辑:

1)我们已经修改了code办理变更推送通知登记iOS8上。下面是code片断:

1) We have already modified our code to handle changes push notification registration for ios8. Below is the code snippet:

//注册推Notitications,如果运行iOS 8
    如果([应用respondsToSelector:@selector(registerUserNotificationSettings :)]){
        UIUserNotificationType userNotificationTypes =(UIUserNotificationTypeAlert |
                                                        UIUserNotificationTypeBadge |
                                                        UIUserNotificationTypeSound);
        UIUserNotificationSettings *设置= [UIUserNotificationSettings settingsForTypes:userNotificationTypes类别:无];
        [应用registerUserNotificationSettings:设置]。
        [应用registerForRemoteNotifications]
    }其他{
        // iOS版8日前注册推送通知
        [应用registerForRemoteNotificationTypes:(UIRemoteNotificationTypeBadge | UIRemoteNotificationTypeAlert | UIRemoteNotificationTypeSound)];
    }

2)更改任何及所有配置设置没有任何帮助,也没有重启设备。

2) Changing any and all configuration settings doesn't helped either, nor does restarting the device.

推荐答案

好像你需要这个请求JSON:声音:默认。空白用来工作,但现在需要的默认使用默认的声音。

Seems like you need this in the request JSON: "sound": "default". Blank used to work, but now needs "default" to use the default sound.

这篇关于没有声音在iOS8上解析推送通知的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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