administrative_areas are stored in the database as their 2 letter abbreviation. I want to convert them to the full name (for use in my own module). I know there must be a function to do this in addressfield module SOMEWHERE but after many long searches I can't find anything...I have a feeling this is being done by super secret ninja elves in an undisclosed location.

How can I convert these abbreviations to full names like addressfield does during node display?

Comments

rszrama’s picture

Status: Active » Closed (duplicate)

Short answer: it's not really possible atm without building the form and extracting a value from the administrative_area #options list. Follow #1829900: [meta] Address Field 2.x needs pluggable administrative areas and an actual API to keep up with a fix for this.