You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by GitBox <gi...@apache.org> on 2018/11/29 15:01:37 UTC
[GitHub] jcms2018 opened a new issue #123: Android Error : Only secure
origins are allowed error
jcms2018 opened a new issue #123: Android Error : Only secure origins are allowed error
URL: https://github.com/apache/cordova-plugin-geolocation/issues/123
Hi, the geolocation is not working on android, I always get the same message, using ionicdevapp + ionic serve -c and also ionic cordova run android on an android device, everything works well on IOS, some idea of how to solve the problem? I have read some forums but it is not clear to me if there is any solution.
Example code :
getPosition():any{
var options = {
enableHighAccuracy: true,
timeout: 5000,
maximumAge: 0
};
this.geolocation.getCurrentPosition(options).then(response => {
console.log('OK');
})
.catch(error =>{
console.log("Error="+ error.code +" =>"+ error.message);
})
}
Error=1
Only secure origins are allowed (see: https ://goo.gl/Y0ZkNV).
Ionic:
ionic (Ionic CLI) : 4.2.1 (/usr/local/lib/node_modules/ionic)
Ionic Framework : ionic-angular 3.9.2
@ionic/app-scripts : 3.2.0
Cordova:
cordova (Cordova CLI) : 8.1.2 (cordova-lib@8.1.1)
Cordova Platforms : android 7.1.4
Cordova Plugins : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 2.2.5, (and 12 other plugins)
System:
Android SDK Tools : 26.1.1 (/usr/local/Android/Sdk/)
NodeJS : v8.10.0 (/usr/bin/node)
npm : not installed
OS : Linux 4.15
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org