Mats Löfdahl <[EMAIL PROTECTED]> writes:

> May I suggest a change in the regular expression that determines
> whether a zip code is US or continental?

You are right of course; in Switzerland and Portugal four digits are
used, and in Germany and France five digits are used (those are the
countries I know about, anyway).

You could therefore set bbdb-continental-zip-regexp to something like
this:
"^\\s *\\([A-Z][A-Z]?\\s *-\\s *\\)?[0-9][0-9][0-9] ?[0-9][0-9]?"

If you find that it works well, the default could be changed.  At the
moment I don't feel to sure about it...  :) And I won't be testing it
because I have all Swiss addresses with the CH- prefix in my BBDB...

> Another thought is, in the absence of zip code country prefix, to look
> at the country field. If it is a European country it should be
> displayed as a continental address. But then one would need a list of
> countries so that might not be a good idea.

The sample code I had for Brazilian and Japanese addresses used an
identifying function that relied on the country names.  You could look
at the mail archive to find the URL of the world post friends (or
whatever the organisation is called) -- they have the "standard" for
all countries of the world, and then you could code the identifying
function and the formatting function for either one.  But it's a lot
of work...  :)

Alex.
-- 
http://www.geocities.com/kensanata/emacs.html
"The bidirectional gnu.emacs.help mail gateway at gnu.org, isn't."

_______________________________________________
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/bbdb-info
BBDB Home Page: http://bbdb.sourceforge.net/

Reply via email to