私はクロスプラットフォームアプリケーションに取り組んでいます。navigator.geolocation は正常に機能していましたが、過去 2 日間から Google chrome で問題が発生しました。API は非推奨ですか、それともこの API のその他の問題ですか? 多くの異なるブラウザとネットワークで次のコードをテストしましたが、それでも同じ問題です。
var options = {
enableHighAccuracy: true,
timeout: 5000,
maximumAge: 0
};
function success(pos) {
var crd = pos.coords;
console.log('Your current position is:');
console.log('Latitude : ' + crd.latitude);
console.log('Longitude: ' + crd.longitude);
console.log('More or less ' + crd.accuracy + ' meters.');
};
function error(err) {
console.warn('ERROR(' + err.code + '): ' + err.message);
};
navigator.geolocation.getCurrentPosition(success, error, options);
エラー (2): ' https://www.googleapis.com/ 'のネットワーク ロケーション プロバイダー: エラー コード 403 が返されました。