Bad Addy
Posts: 0
Joined: Fri Dec 13, 2013 9:34 pm

Push notification services problem cause by device ID

While we develop apps, how do we get around this ';' when updating the device, or is more a case, there is no work round and have to wait ?

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Push notification services problem cause by device ID

Hello, try to use deviceid with encodeURIComponent();

Bad Addy
Posts: 0
Joined: Fri Dec 13, 2013 9:34 pm

Push notification services problem cause by device ID

localStorage.setItem('deviceID', encodeURIComponent(device.uuid));

I used the above, and it failed. Where do I use it ?

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Push notification services problem cause by device ID

Use it when sending UUID value to the service Update Device.

Bad Addy
Posts: 0
Joined: Fri Dec 13, 2013 9:34 pm

Push notification services problem cause by device ID

So I add this to the Add JS, within the REST request. First I need to know if the device id registered.

How I do I put that in the request part ?
Image

Bad Addy
Posts: 0
Joined: Fri Dec 13, 2013 9:34 pm

Push notification services problem cause by device ID

var deviceID = encodeURIComponent(localStorage.getItem('deviceid'));
console.log('deviceid now = ' + deviceID);

The above is what I entered into the JS function.

It comes back as 'Null'

What am I doing wrong ?

Thanks

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Push notification services problem cause by device ID

Try something like this:
pre
var deviceID = localStorage.getItem('uuID');
return encodeURIComponent(deviceID);
/pre

Bad Addy
Posts: 0
Joined: Fri Dec 13, 2013 9:34 pm

Push notification services problem cause by device ID

No, sorry, that did not work. Still the same number after the ';' :(

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Push notification services problem cause by device ID

Strange, it works for me with ';' - can you share your app with a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a? We'll take a look.

Bad Addy
Posts: 0
Joined: Fri Dec 13, 2013 9:34 pm

Push notification services problem cause by device ID

I have shared this. Do I need to give you any information ?

Return to “Issues”