- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
What different in Cordova API and Intel XDK API?
I want use geolocation, what do i should use: geolocation.getCurrentPosition or intel.xdk.geolocation.getCurrentPosition?
コピーされたリンク
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
You should stick to the cordova api's. The intel.xdk api are older and not as maintained as the cordova api's.
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
Thanks for answer!
I tried to change intel.xdk.geolocation.getCurrentPosition to navigator.geolocation.getCurrentPosition and Intel XDK Emulator GeoLocation not work more:
PositionError {message: "Timeout expired", code: 3, PERMISSION_DENIED: 1, POSITION_UNAVAILABLE: 2, TIMEOUT: 3}
Can I fix this?
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
Did you update which plugins you are using in the project settings? You can do so under the Projects tab in the xdk.
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
I open Plugins section in Projects tab. Standart Cordova Plugins - Geolocation 0.3.11 selected.
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
See the demo that we provide on geolocation. Start a new project, Samples and Demos, HTML5 + Cordova, Geolocation.
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
Works for me :) Are you connected to the internet?
Does it work on device for you?
Could your firewall be blocking the XDK from connecting to the internet?
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
try to run app on the actual device instead of in the emulator. i can get the location once deploy to actual device.
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
The Emulate tab and the geo API is kind of tricky if you set it to use an Android device. It is easier to play with if you tell the Emulate tab to use an iOS device. It has to do with the way the Emulate tab interprets the geo JS files for Android. It will work better on a real device.
