Closed martinx1941 closed 5 months ago
Hi valentasm1, i did not mean the google api geolocation. i mean read out the current location direct from the browser
var x = document.getElementById("demo");
function getLocation() { if (navigator.geolocation) { navigator.geolocation.getCurrentPosition(showPosition); } else { x.innerHTML = "Geolocation is not supported by this browser."; } }
function showPosition(position) {
x.innerHTML = "Latitude: " + position.coords.latitude +
"
Longitude: " + position.coords.longitude;
}
It is not related to library at all. 30s google result https://stackoverflow.com/questions/69428693/blazor-user-device-geolocation
function FindLocaiton() { geocoder = new google.maps.Geocoder(); InitializeMap();