Push notification payload with more than one parameter

Getting into LiveCode for iOS? Ask your questions here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
shoshinsha
Posts: 35
Joined: Fri Jul 18, 2014 5:17 am

Push notification payload with more than one parameter

Post by shoshinsha » Wed Sep 17, 2014 4:12 am

Hi,

Is it possible to pass 2 or more parameters per payload?
E.g. to pass newsletter title and a url link.

Mikey
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 755
Joined: Fri Jun 27, 2008 9:00 pm

Re: Push notification payload with more than one parameter

Post by Mikey » Wed Sep 17, 2014 2:40 pm

Remember, the payload is of limited length, but you can encode the payload any way you like, and then interpret it on the other side, BUT you should play with push because LC behaves COMPLETELY differently if the app is open/opened via the user tapping on the notification in the notification center/hitting the launch button/clicking on the banner vs. if the app is not running and the user just launches the app.

It is bizarre and I filed a bug report about it, but no fixey, yet.

The most reliable way to handle push, now, is to have the app check to see if it's badge is set, and then go to some url that you've set and see why it's badge is set. How you do this can get a little tricky, and a little complicated, but that's the way it is for now.

Post Reply