Calling a map with coordinates
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Calling a map with coordinates
I am contemplating software that will call a google map or Bing map to the screen at specified coordinates.
It would be a bit like using URL to call a web address.
For example, a set of coordinates are selected from a database and
might be triggered by something simple like:-
Call Google map 11°19'42.90"N 73°57'56.05"W
Obviously the example is not real, but I am looking for something simple and not get bogged down with Google APIs.
Any help or advice would be greatly appreciated.
It would be a bit like using URL to call a web address.
For example, a set of coordinates are selected from a database and
might be triggered by something simple like:-
Call Google map 11°19'42.90"N 73°57'56.05"W
Obviously the example is not real, but I am looking for something simple and not get bogged down with Google APIs.
Any help or advice would be greatly appreciated.
Re: Calling a map with coordinates
Talk about lucky, I have just figured out the answer myself and it sort of works. All I need now is to figure out how to include the zoom factor.
Example that would be preceded with the URL command http://maps.google.com/?q=@-30.168535,22.950509
Takes you to South Africa.
Any advice on refinements would be wonderful. I think I need to lay down, my brain cell has started to throb.
Example that would be preceded with the URL command http://maps.google.com/?q=@-30.168535,22.950509
Takes you to South Africa.
Any advice on refinements would be wonderful. I think I need to lay down, my brain cell has started to throb.
-
- Posts: 738
- Joined: Thu Sep 11, 2014 1:49 pm
Re: Calling a map with coordinates
Try:
http://maps.google.com/maps/@-30.168535,22.950509,12z
http://maps.google.com/maps/@-30.168535,22.950509,9z
http://maps.google.com/maps/@40.7079112 ... 231,19.25z
http://maps.google.com/maps/@40.7079112 ... 231,15.75z
https://maps.google.com/?q=RequestedPla ... =h&z=19.25
https://maps.google.com/?q=RequestedPla ... =h&z=15.75
Changing the number before the z from 1 to 20 (try higher) should change the zoomfactor.
You do need to use the basic URL http://maps.google.com/maps/
And the pin is gone
Want a Pin: Then you need to add the coordinates after the q=
https://maps.google.com/?q=40.7079112,- ... =h&z=19.25
https://maps.google.com/?q=40.7079112,- ... =h&z=15.75
Regards,
Paul
http://maps.google.com/maps/@-30.168535,22.950509,12z
http://maps.google.com/maps/@-30.168535,22.950509,9z
http://maps.google.com/maps/@40.7079112 ... 231,19.25z
http://maps.google.com/maps/@40.7079112 ... 231,15.75z
https://maps.google.com/?q=RequestedPla ... =h&z=19.25
https://maps.google.com/?q=RequestedPla ... =h&z=15.75
Changing the number before the z from 1 to 20 (try higher) should change the zoomfactor.
You do need to use the basic URL http://maps.google.com/maps/
And the pin is gone

Want a Pin: Then you need to add the coordinates after the q=
https://maps.google.com/?q=40.7079112,- ... =h&z=19.25
https://maps.google.com/?q=40.7079112,- ... =h&z=15.75
Regards,
Paul
Last edited by mrcoollion on Thu Jan 21, 2021 5:15 pm, edited 2 times in total.
Re: Calling a map with coordinates
Hi Paul,
Many thanks, that was a great help, all works as expected.
Kind regards,
Glenn
Many thanks, that was a great help, all works as expected.
Kind regards,
Glenn
Re: Calling a map with coordinates
Hi Paul,
can I also ask, how did you know to add the 'z' for the zoom factor etc - when I tried to google how to do this I was just confronted with lots of javascript code that I couldn't make head or tail of!
Is there an easy reference for the parameters that can be altered for google maps?
Regards,
Glenn
can I also ask, how did you know to add the 'z' for the zoom factor etc - when I tried to google how to do this I was just confronted with lots of javascript code that I couldn't make head or tail of!
Is there an easy reference for the parameters that can be altered for google maps?
Regards,
Glenn
-
- Posts: 738
- Joined: Thu Sep 11, 2014 1:49 pm
Re: Calling a map with coordinates
Hi Glenn,
With the very important and proven method of trial and error.
and some logical thinking
Regards,
Paul
With the very important and proven method of trial and error.


Regards,
Paul
Re: Calling a map with coordinates
Thank you again for taking the time do this.
Regards,
Glenn
Regards,
Glenn