I'm new to phonegap / cordova 3.0, and it looks like I have a similar problem with PhoneGap Help: device properties, cordova v phonegap, xcode debugging . Unfortunately, I have not yet been able to find a solution on the Internet.
After creating the Hello World for iOS example, everything works fine in the simulator. But after changing the contents in index.html with the example code provided for the device properties in the den documentation, the simulator screen shows only โLoading device propertiesโ. Nothing more. For some reason, the onDeviceReady () function is not working properly. Any help is much appreciated
Here is the index.html code for device properties
<!DOCTYPE html>
Device Properties Example
<script type="text/javascript" charset="utf-8" src="cordova.js"></script> <script type="text/javascript" charset="utf-8"> // Wait for device API libraries to load // document.addEventListener("deviceready", onDeviceReady, false); // device APIs are available // function onDeviceReady() { var element = document.getElementById('deviceProperties'); element.innerHTML = 'Device Name: ' + device.name + '<br />' + 'Device Cordova: ' + device.cordova + '<br />' + 'Device Platform: ' + device.platform + '<br />' + 'Device UUID: ' + device.uuid + '<br />' + 'Device Model: ' + device.model + '<br />' + 'Device Version: ' + device.version + '<br />'; } </script> </head> <body> <p id="deviceProperties">Loading device properties...</p> </body>

source share