XML country information
Hi folks, I found the countries_api module the other day as a replacement for the internal ubercart 'geocoding' functionality. I'm thinking after some more research that the location or address module would be a better use of time.
However, both of these modules are incomplete when it comes to full country code information. I'm thinking it'd be a good idea to abstract out the country information that currently exists in the .inc files. Discussion a few years back on some other mailing lists made an XML file similar to the following:
http://pastebin.com/fe4426fa --> XML schema for country codes
I think this would be very useful to implement for the location and/or address module, then bring an nice API together so modules like ubercart and ecommerce can grab country / region / address information without needing to create their own data.
Optionally, we also need to add a field for address format, since each country seems to be a little different. Ubercart has a definition for the 'address-format' field above here: http://www.ubercart.org/docs/user/303/country_settings
It didn't look obvious to me, but perhaps the module already has this support?
I'd much rather integrate these features into a pre-existing module. Ideas?


Yes, it's an issue that needs addressing.
With recidive I'm currently working on a module for country-specific path handling, date display, language setting, views filtering, etc. The first steps are mapped out, http://drupal.org/project/country_code. For this we need data on countries and their languages, etc.
We're looking at geonames. See e.g. this XML web service result for all countries:
http://ws.geonames.org/countryInfo?lang=it&style=full
The geonames module provides various services:
http://drupal.org/project/geonames, http://geonames.edesign.no/
Likely this is our best common format, as it is (a) externally defined (b) available as a web service (c) supported in Drupal (d) regularly updated and maintained.
Maybe countries_api should rely on fetching and caching data from this source, then (like it already does) providing a series of methods for fetching specific excerpts of the data.