Advertisement:

Author Topic: Google Maps location error with item photos  (Read 474 times)

bobadilla

  • Newbie
  • *
  • Posts: 5
Google Maps location error with item photos
« on: October 22, 2017, 03:51:21 am »
This is driving me nuts. I have OS 3.7.4 installed, and have successfully configured Google Maps. I'm using 'city' as my location. The map works fine, every time, except when I add a photo to the listing, whereby the map location is 'lost', with the marker greyed-out and (somewhere over the Equator). As soon as I delete the photo, the location shows up again.

I'm using the Gum theme, and I suspect this is something to do with the Images and Map overlaying panes? It's quite beyond me to even figure out a solution, so I'm hoping for some expert advice here. Thanks.

bobadilla

  • Newbie
  • *
  • Posts: 5
Re: Google Maps location error with item photos
« Reply #1 on: October 22, 2017, 04:52:49 pm »
So I think this may be resolved..  :D
I uninstalled the Google Maps plugin to try out the OpenStreetMap Maps plugin, and among the install parameters for it, where that the plugin requires 'allow_url_fopen = On' in the server php.ini file. I chatted with my host, who fixed that for me, and sure enough, OpenStreetMap began rendering correctly. Unfortunately, it's very slow to load, so I disabled it and re-installed the Google Maps plugin. By coincidence or otherwise, Google Maps now works!

The only issue, which may be a theme conflict, is that 'Gum' shows 2 maps one above the other on item.php. The top map is the one that renders, whilst the smaller map below is greyed-out, but is actually the itemMap div belonging to the Google Maps plugin. To get around that, I simply changed the height to 0px; in the plugin's map.php

bobadilla

  • Newbie
  • *
  • Posts: 5
Re: Google Maps location error with item photos
« Reply #2 on: October 22, 2017, 11:10:14 pm »
Just to add a bit more..
The Google Maps plugin is not saving lat. and long. coordinates in my database whereas the OpenStreetMap plugin is.
If I manually enter the coordinates into the database when using the Google Maps plugin, it solves the problem of the map breaking when adding photos or updating the listing details. The easy solution for me now, is to continue using OpenStreetMap - another great open source project!  ;D