当前位置: 动力学知识库 > 问答 > 编程问答 >

iphone - Can i get the push notification's custom properties when the app is closed or background running?

问题描述:

  1. in iphone,can I get the push notification's custom properties when the app is closed or background running?

  2. When an app(not running) received a push, system generate an alert with two buttons: "Close" and "View". If the user taps View, the application is launched. my question is can i change the action of the "View" button, such as open a web link?

网友答案:
  1. I'm not sure that understood what you need...

  2. Think isn't possible... Only things you can change is button (and body) text. More info you can find in Table 3.2. One of the solution could be, to automatically open a web link, when application is launched from push notification.

    • If the action button is tapped, the system launches the application and the application calls its delegate’s application:didFinishLaunchingWithOptions: method (if implemented); it passes in the notification payload (for remote notifications) or the local-notification object (for local notifications). If the application icon is tapped, the application calls the same method, but furnishes no information about the notification.
分享给朋友:
您可能感兴趣的文章:
随机阅读: