-3

Here is a problem:

  1. Trying to send push notification with URL
  2. Openinig only on last url, not that it Push

can I open WebView controller in didReceiveRemoteNotification?

EDIT: is there any posibility to open webview with another url (not the initial one)?

Amazonian
  • 119
  • 8
  • how about just opening the URL in safari? http://stackoverflow.com/questions/12416469/how-to-launch-safari-and-open-url-from-ios-app – cmyr Dec 03 '14 at 18:06
  • no, sorry, but, safari not an option. On different push notification - there are different url in personal profile open – Amazonian Dec 03 '14 at 18:25
  • didReceiveRemoteNotification is only called (I believe) if your app is currently open. Otherwise, if the user actions the notification, you can check your options in `didFinishLanuchingWithOptions:`. – cmyr Dec 03 '14 at 18:32
  • Tried - with not luck. Also tried in didReceiveRemoteNotification the following code, but it didn't open WebView at all: ` UIStoryboard *mainstoryboard = [UIStoryboard storyboardWithName:@"main" bundle:nil]; WebViewController* pvc = [mainstoryboard instantiateViewControllerWithIdentifier:@"WebView"]; [self.window.rootViewController presentViewController:pvc animated:YES completion:NULL]; ` – Amazonian Dec 04 '14 at 06:27
  • *where* are you trying this? – cmyr Dec 04 '14 at 16:19
  • just found the solution: my mistake was putting [WebView reload] in WillAppear. After removing it - everything working – Amazonian Dec 04 '14 at 22:11

1 Answers1

0

just found the solution: my mistake was putting [WebView reload] in WillAppear. After removing it - everything working

Anbu.Karthik
  • 82,064
  • 23
  • 174
  • 143
Amazonian
  • 119
  • 8