Is it possible to get the latitude / longitude of a user using HTML5 geolocation when they click a button and then redirect to a new page where the values will have been passed to PHP variables?
So if a user is on index.php, which contains the HTML5 geolocation code, and they click on this button;
<span class="button get-my-location">My Location</span>
They'll then be redirected to weather.php where their lat/long will be stored in 2 PHP variables $lat and $long
Is this possible? I assume it would need to be AJAX based? Unfortunately AJAX isn't my strong suit.
Any help would be great