Thomas Thank you, I will try out the Zend Translate.
My question though pointed at the fact that I have these three digit elements mixed in within the 2 char country codes, with no discernable way to sort what countries belong to what 3 digit group. Wouldn't it be better to create a separate method that returned these like getContinentList() It returned: [002] => Africa [003] => North America [005] => South America [009] => Oceania [00?] => Europe And then we marked the relation in the country array as below: And also that I wanted the option to have the countries use there ISO 3 char elements i.e. United Kingdom GB GBR The 3 char in my experience is always better to use, also maybe the dial code is a nice option. So array may be [GB] => array(00?(Europe), United Kingdom, GBR, 44) So these ideas do I put them in a ticket or do they get discussed here first? Again very new so would like to here from people who can comment on these ideas, or indeed use this package to create simple hier selects for continent, country, town etc selections. Cheers Ian -----Original Message----- From: Thomas Weidner [mailto:[EMAIL PROTECTED] Sent: 21 February 2007 20:20 To: Ian Warner; [email protected] Subject: Re: [fw-general] Zend_Locale Hy Ian, > $locale = new Zend_Locale('en_GB'); > $country_array = $locale->getRegionList(); > This provides some functionality > However within the initial array there is continental data > [001] => World > [002] => Africa > [003] => North America > [005] => South America > [009] => Oceania > > It would be nice to delimit on countries or continents etc. And also to > state whether the array should be ISO 2 char or 3 char, and maybe some > flags > to sort this array - either by country code or country. Related to ISO: The ISO Standard defines for regions 2 chars and 3 digit abbreviations for all region strings. But the definition is quite simple... 3 digits represent regions which consist of several countries. 2 chars represent regions where the region is identic with only one country. So if you are only in need of the countries you will have to strip all 3 digit arraykeys. As you will get an array returned the sorting is no problem. Just sort your array the way you want. I think it should be no problem to sort your array by key or value... it would be no simplification to have an additionaly parameter for sorting as there already exist several standard php functions for array handling. > Anyway very new to Zend if I am missing something then I apologise - but > just trying to get my head around this method, is this work in progress? Zend_Locale is finished... actualy there are no opened issues or new feature requests. Btw: You will not have to translate your country with gettext... Zend_Locale already supports all information in all languages natively. And you may want to use Zend_Translate instead of php's gettext... it does not need the extension installed, is threadsave and reads directly from the compressed mo file. Greetings Thomas I18N Team Leader
