39 Posts
jjnxpct
4 years ago
10
Topic

We use the Address to Coordinates Field Plug-in on one of our sites. This plugin stopped working. Not sure why and when... When saving an article the address information is no longer processed by this plugin and the long/lat coördinates remain empty.

We use:

  • Joomla 3.9.15
  • Seblod  3.18.0
  • PHP 7.4

We have removed the restrictions on the API from Google but that did not help. 

Can someone help us debug this please?


Get a VIP membership
39 Posts
jjnxpct
4 years ago
0
Level 1

I do see a PHP warning when saving an article. Not sure if this is related:

PHP Warning: Invalid argument supplied for foreach() in /home/*******/domains/***********.nl/public_html/libraries/src/Form/Form.php on line 1274\n, referer: https://www.*************.nl/administrator/index.php?option=com_cck&view=type&layout=edit&id=500

4 years ago
1
Level 1

Hi jjnxpct,

are you sure that your API Key is fully functional ?

  • API Key: private key (Used by the plugin Google Map) => Must be limited to your domaine
  • API Key (Alternative): Used by the Plugin Coordinate and not visible for public

The 2 keys must not reach the limit fixed by Google.


regards.

39 Posts
jjnxpct
4 years ago
0
Level 2

Hi Lionel,

Thanks for your quick reply.

We only used the 'API Key' until now. We used an API key for Geocoding API in this field. 

We have not use the 'Alternative' API key yet. Are you saying we need to put a key here as well? 

If so, does the first ket have to be for the Geocoding API and the second (alternative)  for Maps JavaScript API? Or the other way around?

Regards, 

Jip.

39 Posts
jjnxpct
4 years ago
0
Level 1

I noticed the City and Postal Code are new? They were empty when I opened it today, but required. I added the form city and postal code filenames here. Not sure if this is related to my issue ;-)

Maybe the screenshots can give you a clue on what might cause the plugin to not work.

39 Posts
jjnxpct
4 years ago
0
Level 1

When I log in to the Google API console I do nt see any attempts to use the API. I think this should show some errors when the plugin is trying to connect with a wrong API key? Or does that nog show up here?

39 Posts
jjnxpct
4 years ago
0
Level 1

To bad I can't get the help I need at this moment. I think we need to figure this out another way, maybe by creating our own plugin.

4 years ago
3
Level 1

Hi jjnxpct,

no issue known on our side, as we have a lot of cases on different websites using this plugin.  

  • Be sure that you have no problem with your API keys.
  • Be sure that you have no error from an other process "Before Store"
  • Try to remove "locatie_plaats" and "locatie_postcode" from the fieldX options.  


Perhaps, you can try the plugin in a simple form with only fields needed.  


If you are familiar with PHP, you can dump the the result of the call in the file:  address_to_coordinates.php

L194 - $geocode   =   $map->geocodeAddress( $address );

Regards.

39 Posts
jjnxpct
4 years ago
2
Level 2

Thanks Lionel. If have tried several things but can't get it to work. When I have some more time I will try it with a seperate new form as you suggested, but for now I have asked my client to just look up the coördinates themselves and fill them out manually. It;s just weird that it stopped working at some point while we did nothing to the form. It might have been a seblod update or the plugin. Or maybe the PHP version (7.3). Maybe I'll figure it out some time later.

3 years ago
1
Level 3

Hi jjnxpct I had the same issue and solved it by creating a new and not hidden addresstocoordinates field. Maybe that help. Could be that the issue was that it was hidden and something was changed with hidden fields.

1 Post
Two
3 years ago
0
Level 4

hi

Get a VIP membership