using cordova.js instead of phonegap.js because it throws a js error otherwise