简体   繁体   English

当我使用我的应用程序时如何关闭其他应用程序的推送通知

[英]How can I turn off push notifications of other apps when Im using my app

I created an app which receives push notifications from my server.我创建了一个从我的服务器接收推送通知的应用程序。 At the same time, if some other app is sending push notifications (for eg, whatsaap, twitter), the notification is getting displayed when I'm using my app.同时,如果某个其他应用程序正在发送推送通知(例如,whatsaap、twitter),则在我使用我的应用程序时会显示该通知。 I want to hide all other app's push notifications except my app's push notifications.我想隐藏除我的应用程序的推送通知之外的所有其他应用程序的推送通知。 Can this be done in iOS?这可以在iOS中完成吗? I want my app to receive push notifications only from my server but not from the other apps.我希望我的应用程序仅从我的服务器接收推送通知,而不是从其他应用程序接收推送通知。

Thanks in advance.提前致谢。

Try to think like your customer.试着像你的客户一样思考。 Would they like to receive the push notifications of the other apps (whatsapp, twitter, the notification that a very important email just arrived)?他们是否愿意接收其他应用程序的推送通知(whatsapp、twitter、非常重要的电子邮件刚刚到达的通知)? Of course they would.他们当然会。 Your App is one of many and most probably not the most important one they own.您的应用程序是他们拥有的众多应用程序之一,但很可能不是最重要的应用程序之一。

Let me provide some background first.让我先提供一些背景。

Your app can only receive notifications from your service/server.您的应用程序只能接收来自您的服务/服务器的通知。

The user might have apps that are receiving notifications from the respective service/server.用户可能拥有从相应服务/服务器接收通知的应用程序。 eg if the user has FB app, then it would be receiving notification from FB servers.例如,如果用户有 FB 应用程序,那么它将接收来自 FB 服务器的通知。

In the end, you are only responsible for managing your service/server.最后,您只负责管理您的服务/服务器。

There is no way for you to block notifications that are received from other services from your app.您无法阻止从您的应用程序的其他服务收到的通知。

Hope this helps.希望这可以帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何接收其他应用的推送通知? - How can I receive push notifications of an other app? 使用Parse在应用程序内打开和关闭推送通知 - Turn Push Notifications On and Off from within App with Parse 当我的Android应用正在播放音乐时,如何关闭所有其他音乐? - How to turn off all other music when my Android app is playing music? 当用户拒绝时,我可以限制用户使用我的应用程序,比如推送通知 - Can i restrict users from using my app when user has declined let say, like push notifications 当我仍在测试我的应用程序时,带有Production-SSL证书的推送通知将起作用吗? 我怎么知道它会起作用? - will push notifications with Production-SSL certificate work when I'm still testing my app? How can I know it will work? 当我的应用程序的音频开始播放时,如何关闭另一个应用程序的音频? - How do I turn off another app's audio when my app's audio starts? iOS 其他应用的推送通知 - iOS push notifications of other apps 如何调试应用的生产证书以获取推送通知 - How can I debug my app's production certificate for push notifications 在创建iOS应用程序(Xcode)时,如何关闭自动图标'gelling' - When creating an iOS app (Xcode), how can I turn off the automatic icon 'gelling' 如何在iOS中打开和关闭通知? - How to turn on and off notifications in iOS?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM