[ic] state.txt file
Dan Bergan
dan at berganconsulting.com
Fri Mar 9 16:17:51 UTC 2012
On Tue, Mar 6, 2012 at 3:17 AM, Lyn St George <lyn at zolotek.net> wrote:
> On Tuesday 6 March 2012 04:20:30 Dan Bergan wrote:
>> Does anyone have a copy of the state.txt file from
>> http://kiwi.zolotek.net/? I'm wanting to try it out, but the download
>> link isn't working...
>>
>> Thanks -
>> Dan
>
> I've been migrating to another machine and a couple of things got missed.
> Found one though and put it there for you
When testing this state.txt, I noticed that the "header" records for
the UK are not appearing when using the state_select and
country_select widgets.
In the UK:
-- England --
-- Scotland --
-- Wales --
-- Nth Ireland --
only the first entry "-- England --" will appear in the state_select
widget. For each of these entries (plus the "N/A" record) the state
field is blank, and it appears that country_select is removing
duplicates.
for(keys %states) {
my $sa = $states{$_};
my @sv;
my @st;
my %seen;
@$sa = grep !$seen{$_->[0]}++, @$sa;
I was going to make a small change to this so that duplicates are
allowed if the state was blank, but I was just wondering if there were
any other solutions? Lyn, do you use the standard "country_select"
and "state_select" widgets with your state.txt file?
Thanks -
Dan
More information about the interchange-users
mailing list