Address Field

The Address Field module provides a Drupal 7 field for standardized storage of postal addresses based on the OASIS xNAL standard.

Address Field provides one or more addresses to an entity, module, or user. It understands the differences in address styles for each country, and offers per-country edit forms and formatting.

For example, for Australia:

City might be the city and, in the case of a big city, is usually the suburb. An address in Wahroonga is usually Wahroonga but might be Wahroonga, Sydney.

We have states: ACT, NSW, NT, QLD, SA, TAS, VIC, and WA. An address in Wahroonga is Wahroonga NSW.

The postal code is usually called postcode and is a four-digit integer with the first digit indicating a state. NSW postcodes start with 2. Sydney is 2000. An address in Wahroonga is Wahroonga NSW 2076.

For a review of the module's inner workings, see the Address Field from a code perspective.

How to use adressfield with tokens / rules see Using tokens with addressfield

Address Field "Required" or not

If a country is selected for an address field, then certain sub-fields of the address will always be required to be filled in. This is so

Address Field from a code perspective

For those who develop code, the address appears in the database as a field added with an array containing the address components. You might

Convert country name to 2 letter country code with Google geocoding and migrate

Here's a suggested starting point for someone migrating into Address Field with country names in the source. This does Google geocoding

Importing Address Field data with Feeds

The Feeds module may be used to import Address Field data into entities containing address fields. Address Field stores the individual

Using tokens with addressfield

It is possible to get tokens from an addressfield.

Guide maintainers

peterx's picture