Skip to main content.
home | support | download

Back to List Archive

Re: warning: Failed to convert internal UTF-8 to Latin-1

From: Jacob Friis Larsen <jfl(at)not-real.list.idg.dk>
Date: Thu Aug 12 2004 - 11:14:30 GMT
>>Well now I get "warning: Failed to convert internal UTF-8 to Latin-1".
>>
>>I use Php and convert UTF8 to Latin-1, but that doesn't seem to be enough.
>>Should I also use htmlentities($text) which will convert all applicable 
>>characters to HTML entities?
> 
> There's nothing you can do.  You likely have a character that doesn't map
> to Latin-1.
> 
> libxml2 uses converts to UTF-8 internally and that's what the libxml2
> parser outputs.  Swish only knows how to deal with 8-bit chars so it
> has to convert to an 8-bit encoding, and libxml2 provides a function
> to convert from UTF-8 to Latin-1.  Not all UTF-8 can be converted to
> Latin-1, of course.

When not converting UTF8 to Latin-1 and only using htmlentities($text) I 
get only a few errors. That's fine :)

Thanks,
Jacob
Received on Thu Aug 12 04:22:21 2004