Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Occasionally, when dealing with data that was migrated/converted from something else it can be a large hassle to handle incorrectly entered address information. A particular problem is the province field, which Location.module expects to be a one, two, or three-character string that is uppercased to fit the lookup arrays stored in the 'supported' directory. It would be occasionally useful if, until the data can be manually massaged & verified, province strings that were not found in the supported index for the specific country could be passed through to the front end as-is.
Comment | File | Size | Author |
---|---|---|---|
#4 | location-province-fallback-890290-4-D6.patch | 499 bytes | jwilson3 |
#4 | location-province-fallback-890290-4.patch | 499 bytes | jwilson3 |
Comments
Comment #1
DamienMcKennaHere's a patch that only uppercases the string if it is two characters in length.
Feel free to mark this as WONTFIX as this is kind of a fringe issue that in normal circumstances shouldn't happen.
Comment #2
podarokall feature requests should be rolled against latest 7.x-3.x-dev and after commit can be backported to 6.x branch
Comment #4
jwilson3Code in D6 has changed significantly since this patch was created, so I've updated the patch to work with how the province names work in the version 3 branch of both D7 and D6 to let unknown province codes pass through as-is.
Comment #7
podarok@jwilson3 thank you tons.
Committed to both branches
Comment #8
jwilson3Sweet! Thanks.