Skip Navigation

[Resolved] Google Map plugin- importing addresses

This thread is resolved. Here is a description of the problem and solution.

Problem: Where are the Latitude and Longitude stored for the Toolset Maps Fields?

Solution Please refer to this answer: https://toolset.com/forums/topic/storage-location-of-latitudelongitude/#post-413214

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Tagged: 

This topic contains 3 replies, has 2 voices.

Last updated by Beda 5 years, 2 months ago.

Assigned support staff: Beda.

Author
Posts
#361944

I have successfully installed the Google Maps plugin from Toolset, I can enter into an address field and the map shows properly.

My problem is that in my real estate site, I import my data nightly us the WP All Import plugin. I tried just importing the address in the correct format, but that did not work. You have to go into the manual edit mode and input the address in order to see the map.

The good thing is that I actually have the lat and long coordinates - so I'm guessing I'm going to have to actually reverse-lookup the address from the coordinates and grab the correct google address to place in the address field?

Am I making this too hard?

#362003

This is strange, because if you copy/paste a VALID Google address to the Field, even if you do NOT click on the appearing dropdown address picker, but just save the Post with the address (copy pasted previously), you will (after save) see the proper address marked on the map next to the field.

See this example:

1. Malaysian Nature Society Kuala Lumpur Federal Territory of Kuala Lumpur Malaysia
2. Copy paste above to the Address Field
3. Click OUTSIDE the field area, as example in Post Editor
4. Save and see the address.

If you import CF Data with a Plugin, and store the correct addresses, that should work the exact same way.
As importing the data your way also doesn't trigger the map locator, and that's the same as I did above.

Can you elaborate the exact steps to follow, to reproduce the issue?

As for the latitude / longitude, we store those as a option in the DDBB.
The options name is toolset_maps_address_coordinates and it stores a array, as for above address example:

a:1:{s:32:"9f82085d1b14342ffb2da6367571eead";a:4:{s:3:"lat";d:3.139854600000000051096549213980324566364288330078125;s:3:"lon";d:101.6808350000000018553691916167736053466796875;s:7:"address";s:107:"Malaysian Nature Society, Bukit Persekutuan, 50480 Kuala Lumpur, Wilayah Persekutuan Kuala Lumpur, Malaysia";s:14:"address_passed";s:80:"Malaysian Nature Society Kuala Lumpur Federal Territory of Kuala Lumpur Malaysia";}}

In Toolset Maps 1.1 there will be a possibility to store a meta value as

{1.11, 2.22}

which meains latitude:1.11 and longitude 2.22

Please let me know if you have further questions regarding the issue mentioned in this Thread

Thank you for your patience.

#362204

You are correct - my error. However, the coordinate info was helpful. My issue is closed, I was not importing the field correctly.

#413215

Please refer to this Post for some corrections on my above statement and the current (and so-to-be) behavior of Toolset maps:
https://toolset.com/forums/topic/storage-location-of-latitudelongitude/#post-413214