Require: Maps Lat/Long on click displayed in fields + stored (for submit) & Form results (and attachments) saved in Google Sheets/Drive

1) We need support with extending the google maps script that should:
  1. locate the visitor's location (if permission given or fall to a default location if not)
  2. on click retrieve the lat/long (done) and store them as variables + display them in the fields below the map + export them on submit
The above should happen on multiple instances of map/fields in the same form.
Current script in use:
<div id="googleMap" style="width:100%;height:400px;"></div>

<script>
function map() {
var mapOptions= {
center:new google.maps.LatLng(45.301612095081865,20.304201962039922),
zoom:18,
mapTypeId: 'satellite',
disableDefaultUI: true,
zoomControl: true,
mapTypeControl: true,
mapTypeControlOptions: {
style: google.maps.MapTypeControlStyle.DROPDOWN_MENU,
mapTypeIds: ["roadmap", "terrain", "satellite", "hybrid"],
},
scaleControl: true,
streetViewControl: false,
rotateControl: true,
fullscreenControl: true
};

var map=new google.maps.Map(document.getElementById("googleMap"),mapOptions);

google.maps.event.addListener(map, 'click', function(event) {
alert(event.latLng.lat() + ", " + event.latLng.lng());
});

}
</script>
<script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyB6Po46QiITiYqlAKCQ_7MTt3ZUMAD1QaM&callback=map"></script>

2) We need support in storing the uploaded images to Google Drive and form submission to Google Sheets.

This is a request that needs to be processed by EOW so please contact me asap.
You need to login to be able to post a reply.