Separate access to address fields?

Created on 24 October 2023, about 1 year ago
Updated 6 November 2023, about 1 year ago

Just a quick question and maybe a feature request (if it doesn't already do it):

1. Question: What is the difference between the webform field types "Location (AddressFinder) - Full Address Only" and "Location (AddressFinder)"? I couldn't find any documentation on it. I thought one maybe didn't support PO Boxes - but both of them did.

2. Feature request: Not sure if this is already handled in the module, but once an address is validated, is there somewhere this field is exposed as separate address field items like, street1, street2, suburb, postcode, city, country, etc...? I need to send the validated address to an external service which requires individual fields for the address.

Any help/documentation would be appreciated.

Thanks for the excellent work!

Cheers
ST

Feature request
Status

Active

Version

1.5

Component

Code

Created by

🇦🇺Australia steventpmc

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @steventpmc
  • 🇦🇺Australia nigelcunningham Geelong

    Thanks for your query.

    The address only version does a simplified version - a single line field that lets you enter just a full address on one line (eg 234 Somewhere Street, Someville 3000, Victoria). The full version provides separate fields that let you enter a house number separately to the street name and so on. The full version does also include the "Full version" field but that's only because it includes all fields that the API provides.

    Regarding whether you can access the individual parts of the address post-validation, we don't do anything there at the moment but it looks to be possible. The AddressFinder API provides a way to get location metadata (https://addressfinder.com.au/api/au/location/metadata/). I'll see what I can do for you.

  • 🇦🇺Australia nigelcunningham Geelong

    Hi again.

    I was wrong in the previous comment - we did have some code to do what you ask, but it was broken, perhaps by changes upstream since it was written. Whatever the case, I've now pushed fixes/improvements to the dev branch.

    If you use the full control (the multiple fields version), it will now populate the other fields when you type an address into the field field and pick an entry from the autocomplete.

    Could you check out whether it achieves what you're after?

    Thanks!

    Nij

Production build 0.71.5 2024