Revised ajax call in geolocate.js