ios - Getting push notification payload when user opens app manually after push has been received in the background -


I am using iOS 7 and I am trying to determine whether I am using JSON payload I can get it.

  • I have background mode "Remote-Notification" enabled
  • App Finish
  • Push Notification Receives Notice After launching the icon do not

I launch the application.

- The (BOOL) application does not get pushed into the launch options: (UIApplication *) was applied to FinishLaunchingWithOptions: (NSDictionary *) launchOptions;

and the following method is not called when the app is manually started with the icon

- (zero) Application: (UIApplication *) ReeseiveRemoteNotification: (NSDictionary *) userInfo fetchCompletionHandler: (void (^) (UIBackgroundFetchResult)) Full Hondeller {

Finally I Thought how you can get it!

As iOS 7 you can get it!

Basically, you have to configure your application for background remote notifications.

Therefore, in your information.Pilist file: for the required background - Set it from push notifications to app download content.

In the AppDelegate.m file, you need to implement this method:

- (zero) Application: (UIApplication *) application did the receiver notification: (NSDictionary *) userInfo FetchCompletionHandler: (Zero (^) (UIBackgroundFetchResult)) End Handler

To apply it, see:

For your push notifications, you must have content-available ': 1, as part of the push notification. This is the app that has new content before displaying the warning.

See this page for more information on background remote notifications:


Comments