[Israel.pm] UTF-8

Pinkhas Nisanov pinkhas at nisanov.com
Thu May 3 13:42:26 EEST 2007


On 5/3/07, Gaal Yahas <gaal at forum2.org> wrote:

> Not in general. Given a string you can tell if it's valid UTF-8 or
> not, but *all* strings are valid ISO-889-1! (Modulo perhaps one or two
> byte patterns that don't appear in UTF-8 either). So you need some
> sort of heuristic; perhaps scan characters until you see something
> that isn't valid UTF-8 and assume it's a single Latin-1 character and
> translate it accordingly.


Thanks



More information about the Perl mailing list