What is the Addressfinder extension for Magento 2?
- The Addressfinder Magento address autocomplete plugin adds Australian and New Zealand address autocomplete capability to the billing and shipping address fields within your Magento 2 store.
- Get Verified addresses - No more mistakes. Save addresses straight from your webform to your database.
- Access the latest addresses - Database refreshed monthly for up-to-date addresses.
- No software required - Addressfinder is a Javascript widget and API.
- Supports all modern browsers - Addressfinder for Magento 2 will work in all modern browsers. Internet Explorer is supported from version 9 to current.
Installation
- We suggest that you install Addressfinder via composer. The steps below outline this process, and work for Magento versions 2.1, 2.2, 2.3 and 2.4. Magento 2.0 is no longer supported. If you would prefer to install via the Magento marketplace you can find our extension here. If you prefer to install via ZIP, download the file from GitHub
- 1. Open the terminal and go to your Magento installation directory and enter:
composer require addressfinder/module-magento2
This installs the Addressfinder extension within Magento. This takes about five minutes. - 2. Once installation is completed, enable the Addressfinder module by entering:
bin/magento module:enable AddressFinder_AddressFinder
- 3. Run the setup:upgrade command:
bin/magento setup:upgrade
- 4. Clear the cache:
bin/magento cache:flush
- 5. You may need to recompile your dependency injection cache and redeploy themes, especially in production. This process, which varies from site to site and is outside the context of installing this module, generally involves the commands:
bin/magento setup:di:compile
bin/magento setup:static-content:deploy
Enabling and configuring the widget
Configure the extension within the Magento Admin settings
- Click on 'Stores' in the side bar, and 'Configuration' from the slide out menu. Select 'Services', then Addressfinder.
- Uncheck the 'Use system value' checkbox.
- Set 'Enabled' to Yes.
- Enter your Addressfinder licence key. If you don't have a licence key yet, you can get one by signing up for a trial plan.
- To refine your search, you can add the following code to the widget options:
-
To search physical addresses (Default):
{"address_params": {"gnaf": "1"}}
-
To search Australia Post addresses (including PO Box address types):
{"address_params": {"au_paf": "1"}}
-
To search Australia Post addresses (excluding PO Box address types):
{"address_params": {"au_paf": "1", "post_box": "0"}}
-
To search physical addresses (Default):
- Press the Save Config button.
- You can test the extension on the Checkout page of your store, or on the Address Book section of your customer account.
- When you test, select either 'Australia' or 'New Zealand' in the country field of the checkout, then search an address.