6

Has anyone used a proximity filter or sort in Drupal Views based upon a contact's geocoded address? I think it would be doable with the GeoPHP module and a special handler, but I don't know if it has been done.

2
  • 2
    I'm actually working on an implementation today. Apr 1, 2015 at 14:46
  • Please publish this when done, @Jeremy Proffitt.
    – Joe Murray
    Apr 2, 2015 at 21:00

2 Answers 2

6

We've done this with OpenLayers https://www.drupal.org/project/openlayers and Openlayers Proximity https://www.drupal.org/project/openlayers_proximity

I wrote a blog article which in part describes how to create a OpenLayers map and Openlayers Map Views overlay with CiviCRM Event location plotted on a map. This should give you enough pointers to design your own Openlayers Map, View and get you started: http://jackrabbithanna.com/articles/drupalcivicrm-integration

This article does not include the Proximiy functionality you are looking for, but just install Openlayers Proximity and the filtering will be made available in the Views UI

0

I've just set up a proximity search using this new-ish module: https://www.drupal.org/project/civicrm_contact_distance_search

About to see if I can use something like Leafet to add a map as well.

2
  • hmm - shame we didn't spot that. just did a bunch of work to do a drupal side 'search by proximity and then save as Smart Group' work.
    – petednz - fuzion
    Feb 12, 2017 at 19:03
  • I only came across it by chance myself. I was looking at the Openlayers-based approach which looked like sledgehammer to crack nut. Would be great to get something like this re-written as an extension.
    – Graham
    Feb 14, 2017 at 9:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.