I updated to 5.x-3.0-rc2 and enabled the Location Search module. Attempting such a search resulted in the following error:

Fatal error: Call to undefined function: gmap_set_location() in sites/all/modules/location/contrib/location_search/location_search.module on line 264

Presumably, either the Location Search module needs to add gmap to its list of dependencies, or this call needs to otherwise be guarded. Otherwise, things are working well. Thanks!

Comments

jsheffler’s picture

Priority: Critical » Normal

OK, I just found the "Use map to pick search coordinates" toggle on the admin/settings/location/search page. Turning it off allows proximity searching without gmap, and avoids this error, so I changed the priority from "critical" to "normal". Nevertheless, this setting is turned on by default "out of the box". I would suggest three things:

  • Leave this toggle off by default (at least, if gmap is not installed);
  • Add a note on this page indicating that turning this option on requires gmap; and
  • Guard the call with function_exists('gmap_set_location')

Again, thanks.

dynamite’s picture

I have gmap and location modules installed and enabled. Toggling the option as suggested above doesn't fix the proximity search problem, unfortunately. Any other suggestions when both gmap and location are enabled?

yesct’s picture

dynamite, unless you were getting the same error: Fatal error: Call to undefined function: gmap_set_location() in sites/all/modules/location/contrib/location_search/location_search.module on line 264

You will probably get a better response if you open your own issue and describe your specific circumstances of what is not working. :)

About the gmap requirement, please confirm this is still an issue in the latest dev version (or 3.1 version). If it is still a problem, maybe we can get someone to write a patch to add the warning you suggest.

yesct’s picture

Status: Active » Closed (fixed)

no comfirmation this is still a problem since a year+. Closing. If this is still a problem, try out the newest official release or dev and post an update, making sure to change the status back to active. Thanks.