在后台模式下未收到 iOS APNS [英] iOS APNS not received in background mode
问题描述
我正在尝试在后台模式下接收通知.我不希望用户在收到通知中的警报时启动我的应用程序.但似乎 iOS 并没有将通知发送到回调函数 didReceiveRemoteNotification:任何输入?
I am trying to receive a notification when in background mode. I don't want the user to launch my app on receiving an alert in the notification. But it seems like iOS doesn't send the notification to the callback function didReceiveRemoteNotification: Any inputs?
为了在后台模式下接收推送,我需要执行一些特殊的操作吗?
Is there something special I need to perform in order to receive a push in the background mode.
仅供参考:我也尝试使用 voip 后台模式,但仍然没有!!!
FYI : I tried using voip background mode also and still nothing!!!
基本上我希望我的应用程序在不启动我的应用程序的情况下收到通知,并在应用程序在后台运行时执行一些操作.
Basically I want my app to receive a notification without launching my application and perform some action while application is running in background.
推荐答案
但似乎iOS并没有将通知发送到回调函数didReceiveRemoteNotification:
But it seems like iOS doesn't send the notification to the callback function didReceiveRemoteNotification:
确实如此.如果您的应用在后台运行,您将不会收到有关传入推送通知的通知,除非用户通过与通知警报交互实际启动应用.
That's true. If your app is in the background, you will not get notified about an incoming push notification unless the user actually launches the app by interacting with the notification alert.
基本上,我希望我的应用能够收到通知,而无需用户启动我的应用/用户干预并在后台运行时执行某些操作.
Basically I want my app to receive a notification without user having to launch my app/ user intervention and perform some action while running in background.
这不可能.
这篇关于在后台模式下未收到 iOS APNS的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!