Discussion:
Map url in Browser Widget
Mike for GDC via use-livecode
2018-12-06 23:55:58 UTC
Permalink
I currently put the following URL into my browser widget and it works ok but
does anyone know what needs to be added to the code in order to place a
"marker" into the map location? I want the user to see the exact location
of where they are located. I get the Lat / Long from the
"mobilecurrentlocation" command.



This is what I generate now:

https://www.google.com/maps/@45.829321,-109.904418,10z

Thanks.



Mike
hh via use-livecode
2018-12-07 14:28:30 UTC
Permalink
... does anyone know what needs to be added to the code in order to place a
"marker" into the map location? ...
http://maps.google.com/maps?q=45.829321,-109.904418&z=10&t=h

The t=h is for a hybrid view

Another example, for a text query:
https://www.google.com/maps?q=rm+kerner+company&z=10&t=h

Most of this works (scroll the page halfway down):
https://moz.com/ugc/everything-you-never-wanted-to-know-about-google-maps-parameters
hh via use-livecode
2018-12-08 20:09:58 UTC
Permalink
The examples of my last post show a marker but ignore the initial zoom.
The following shows the marker and also respects the zoom (1-19).
(Tested on desktop only).

on mouseUp
put 8 into z
put 45.829321 into la
put -109.904418 into lo
set url of widget "browser" to \
merge("https://www.google.com/maps/place/[[la]],[[lo]]/@[[la]],[[lo]],[[z]]z")
end mouseUp
... does anyone know what needs to be added to the code in order to place a
"marker" into the map location? ...
http://maps.google.com/maps?q=45.829321,-109.904418&t=h
The t=h is for a hybrid view
https://www.google.com/maps?q=livecode+edinburgh&t=h
Continue reading on narkive:
Loading...