Page 1 of 1

Getting the device UUID

Posted: Wed Feb 13, 2013 6:58 am
by David5542897

Hi,
Is there a way of getting the device's UUID (or equivalent for Android)?
I know it's supported on phonegap, but how can I get the data on Tiggzi?

Regards,
David.


Getting the device UUID

Posted: Wed Feb 13, 2013 6:59 am
by maxkatz

Use PhoneGap API - it's automatically included in the project (http://docs.tiggzi.com/getting-started).


Getting the device UUID

Posted: Wed Feb 13, 2013 7:37 am
by David5542897

Thanks for the prompt reply.

I want to store the uuid in localStorage on page load.
I put this in the JS window -

codevar string = device.uuid;
localStorage.setItem('device_uuid', string);
/code

However, the page will not load (stuck on the ajax spinning icon).
I'm testing both on my desktop browser and on my iphone browser.

Is there something I'm missing?


Getting the device UUID

Posted: Wed Feb 13, 2013 8:59 am
by Maryna Brodina

Hello! It won't work in browser. You would need to install app on device.


Getting the device UUID

Posted: Thu May 02, 2013 5:14 pm
by pafowkes

Just in case somebody else happens to look for this question I was trying to do this myself, seems you need to add the event on 'device ready' as it doesnt work on page load.


Getting the device UUID

Posted: Wed Sep 10, 2014 9:39 am
by rajiv gupta

<!DOCTYPE html SYSTEM

Code: Select all

 Device Properties Sample 

' +
'Device Cordova: ' + device.cordova + '
' +
'Device Platform: ' + device.platform + '
' +
'Device UUID: ' + device.uuid + '
' +
'Device Model: ' + device.model + '
' +
'Device Version: ' + device.version + '
';
}

Code: Select all

  Loading device properties... 

Getting the device UUID

Posted: Wed Sep 10, 2014 9:40 am
by rajiv gupta

trying this but unable to get device configuration..please anybody help me to getting device information


Getting the device UUID

Posted: Wed Sep 10, 2014 11:00 am
by Evgene Karachevtsev

Hello Rajiv,

Unfortunately it looks like that your code is displayed in corrupted way. Could you please repeat it with using tag code?


Getting the device UUID

Posted: Sat Oct 11, 2014 10:15 pm
by Daniel Wong

It seems that accessing device.uuid in the app will cause the page to hang.

I put a simple javascript like this:

alert("device uuid: " + device.uuid);

when a page is load. It hangs even when I install the app on the phone itself. Can we have better example on how this works?

Thanks


Getting the device UUID

Posted: Sun Oct 12, 2014 7:10 am
by Illya Stepanov

Hi Daniel,

Try using "deviceready" as it's in example in the PhoneGap documentation: http://docs.phonegap.com/en/3.3.0/cor...