推送通知不起作用 [英] push notifications not working

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

问题描述

我知道这个问题已经有人问过了,但我迫切需要答案.

我正在我的应用中实施推送通知.最初一切正常,我收到警报.但是有一天我的证书过期了,我更新了证书并使用了更新后的 p12 文件.

I was implementing push notifications in my app. Initially everything was working fine and I was getting alerts. But one day my certificate expired and I renewed the cert and used the updated p12 file.

我重新生成了 pem 文件.但现在我不再收到警报了.

I regenerated the pem files. But now I stopped getting alerts.

我想可能是我的 p12 文件有问题,所以我重新生成了几次.但是推送通知不起作用.

I thought that may be I there could be some issue with p12 files so I regenerated them several times. But push notifications don't work.

请提出解决此问题的建议.提前谢谢.

Please suggest something to resolve this issue. Thanx in advance.

推荐答案

我的问题得到了解决.

根据苹果文档,有时由于连接不稳定,设备无法与 APNS 连接.因此,为此您需要经常从设置"应用打开关闭通知,以便与 APNS 重新建立连接.

According to apple docs sometimes due to impersistent connection the device is not able to connect with APNS. So for this you need to on-off Notifications from the Settings app frequently so that the connection is regained with APNS.

希望这可以为许多陷入此问题的人节省大量时间.

Hope this saves a lot of time of many people stuck in this issue.

这篇关于推送通知不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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