Ray wrote:
> In general, support questions should be posted to Stack Overflow, or the
> Google group.
> This list is for the *development* of Cordova itself.
> That being said, you probably forgot to add the plugin.
Ray is probably right, but I'll add two other notes:
> <script type="text/javascript" charset="utf-8"
> src="../../js/cordova-2.2.0.js"></script>
The current version of Cordova is 3.5...
> function checkConnection() {
> var networkState = navigator.connection.type;
> var states = {};
> states[Connection.UNKNOWN] = 'Unknown connection';
...
> states[Connection.NONE] = 'No network connection';
You really shouldn't build an object like this for one time use. Either create
the object once somewhere, or use a switch statement.
> alert('Connection type: ' + states[networkState]);
> }