I am writing a PhoneGap application that sends requests to a central database. It should be able to identify unique devices that connect to it.
The PhoneGap device.uuid property seems to do the trick. On webOS and iPhone, I am returning a unique string of alphanumeric characters that will satisfy my need. However, the Android devices I tested (Motorola Droid and Android SDK emulator running Android 2.1) return "undefined" as device.uuid .
device.platform and device.name return the correct values ββon all three platforms, so the problem is not related to the device object itself (it is defined in the code blocks where I use it).
Is this a limitation of Android? Problem with PhoneGap?
Is there any other way to get such a globally unique identifier, if not through device.uuid ?
EDIT: It looks like the deviceready event never fires, which should happen before the device.uuid property becomes available.
source share