replaced the onblur with onfocus to improve the timing of calling the geolocation