Install

Works with Drupal: 7.x

Using Composer to manage Drupal site dependencies

Downloads

Download addressfield_lookup-7.x-2.0.tar.gztar.gz 26.68 KB
MD5: 1fa48a7084c5190c0c7651ccacffc834
SHA-1: 98c785dd635546af58b884fdc0948ab499295846
SHA-256: 92b98128e0ec015e96f3f0039a2376de706fc87d1d5849e17ea10d20371f11ed
Download addressfield_lookup-7.x-2.0.zipzip 39.04 KB
MD5: 7f8b53546ce7674d27357e6cc2b36250
SHA-1: 67ca780e373231f2a00e036387a97a13cdedbb15
SHA-256: e653ad37be033b1c87b4778b5b20f5b9f54ccef57a49133f6432c1fce0a5fe23

Release notes

Address Field Lookup 2.0

The time has come for a the second major release of Address Field Lookup. This release is the culmination of code reviews and real world usage of the module over the past 6 months. This release greatly simplifies the integration process for developers of lookup services; the interface is much simpler with only 2 functions defined. The release also makes the module codebase much more maintainable and easier to manage.

These changes make this release incompatible with 1.x era integrations. API breaking changes can be found in API.txt in the module folder; but can also be found below.

  • Refactored setLookupTerm(), lookup() and getLookupResult() functions into a single function - lookup($term). This function now accepts the search term as a required parameter and returns either the array of search results or FALSE if no results could be found.
  • All integrating modules must define a 'object factory' key in their implementation of hook_addressfield_lookup_service_info. This key refers to a function responsible for instantiating the PHP class that implements the AddressFieldLookupInterface interface. The function receives the service info array as a parameter.
  • hook_addressfield_lookup_get_service_object no longer exists. Any module functions implementing this hook will not be invoked. See the 'object factory' details in the above bullet point and the example module which can be found in tests/modules/addressfield_lookup_example.
  • The functions addressfield_lookup_get_addresses() and addressfield_lookup_get_address_details() no longer accept a $show_errors parameter. The 2nd parameter on both functions is now the cache reset parameter. See addressfield_lookup.module for more details.
Created by: danielmrichards
Created on: 30 May 2016 at 16:54 UTC
Last updated: 16 Jun 2016 at 21:15 UTC
Bug fixes
New features

Other releases