Home  >  Q&A  >  body text

iOS 推送时如果APP在前台运行推送通知不会弹出吗?有解决方法吗

iOS 推送时如果APP在前台运行推送通知不会弹出吗?有解决方法吗?前台运行能弹出推送通知吗?我想后台运行进入和前台运行分两种处理方式,我应该如何处理

PHP中文网PHP中文网2741 days ago711

reply all(3)I'll reply

  • 高洛峰

    高洛峰2017-04-18 09:25:42

    Will the push notification not pop up if the APP is running in the foreground during iOS push?
    Answer: No.
    When the app is not completely closed ↓
    When the app is in the foreground: notifications can be received, but not displayed
    app is in the background: notifications can be received and displayed
    When the app is completely closed ↓
    Click the program icon: enter the app main interface
    Click on the notification: Enter the details page

    reply
    0
  • ringa_lee

    ringa_lee2017-04-18 09:25:42

    If your application is in the foreground and receives a push, then the application:didReceiveRemoteNotification: method of your appdelegate will be called by the system and passed to you the push content. Just handle the push in this method

    reply
    0
  • 黄舟

    黄舟2017-04-18 09:25:42

    You can try the pop-up effect when the iOS front desk receives a push ^_^
    https://github.com/Yasashi/EB...

    reply
    0
  • Cancelreply