Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Web Viewer - Geocoding/mapping Google Maps (simple marker) doesn't mark over sea area.

Featured Replies

Hello,
I am running FM12 Advanced (Windows), and I have a small issue regarding geocoding with Google Maps (simple marker).
My FM-database contenins many different location records, and a fuction to call the layout with the Web-viewer and geocode/mark the location on Google Maps.
The problem is that  although there are coordinates (Lat / Lgn), GoogleMaps does not display the map when the coordinates (Lat / Lgn) are crossed somewhere over sea area, for example, the Atlantic Ocean, Mediterranean sea, and so forth.
The problem is best illustrated on the attached demo DB (DEMO_LocalitiesGoogleMap.fmp12) which contains three locality records:
1) United Kingdom, London, 21 Picadilly str.
2) Turkey, Antalya, Latitude: 36,808, Longitude: 31,762
3) Atlantic Ocean, Latitude: 50.66, Longitude: -28.59
With records 1 and 2, there is no problem mapping the location on Google Maps, while the same does not happen with record 3.
Any help to solve the mystery is greatly appreciated.

DEMO_LocalitiesGoogleMap.fmp12

Edited by asterix

You seem to me to be doing it the hard way.  If you have lat and long, why not just pass lat and long in your html, if you have a full physical address, pass that.  I also don't understand why it's in a separate table, but this may just be a small sample part of your DB

Edited by Steve Martino

  • Author

Steve,
Yes, this is a very small sample to demonstrate my issue.
The html and the zoom are in a separate table "Global_Settings" for a reason (I have quit few other global settings (not included in the Demo I uploaded) and it is  convenient to have them all in one table..
My database contains a lot of records, many with full physical address with  lat/long, others only Country and state, and many lat/long records pointing at a specific locality over a given sea, i.e. Atlantic ocean, Pacific ocean, Mediterranean sea and etc. The latter is my issue, Google Maps won't display them. I don't know why. 

It may help if you describe what you are looking for as a final result. Do you:

1.  Just want a static map in the webviewer with a pin for the location?

2.  Want an interactive map?

3.  Want to plot just one point or multiple points?

  • Author

Thank you Steve!
What I want exactly is the same kind of map as shown in the Demo.
(a map that by use the of mouse, can be zoomed in and out, and be moved to all directions)

This is what I use.  Works for single record or multiple records.  I can dig into it deeper tomorrow.

https://community.filemaker.com/docs/DOC-3321

There are custom functions for extracting lat and long out of an address, or just use lat and long.

FM Starting point (free) has a very nice DB with a contacts module that has very nice mapping features.  One of the scripts will auto populate lat and long from an address.

Sometimes when I have to map something off road, there's also some reverse geocoding custom functions with the Contacts starter solution (I think for FM12).  I'll have to check all of this tomorrow when I'm on a computer and not my iPad.

  • Author

Thanks for your suggestion Steve.
I made my acquaintance with those Mapping and Geolocation functions last week while I was searching the internet in hop to find a solution to my problem. No doubt, they are excellent, but are not what I need.
The ideal solution for me (and hop) is, someone to have a look at my uploaded file (DEMO_LocalitiesGoogleMap.fmp12), figure out why the Gmap is not displayed when the Lat./Lgn. lines are crossing each other over sea, and make it work, possibly by modifeing the html text, or something else.
It's of paramount importance for me the fuction to basicaly remain the same as is in my DEMO file. That is;
1) one point plot, satellite and map view,
2) the map is zoomable, and draggable to all direction,
3) the web viewer (map) opens in seperate layout.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.