[dev] iconv and mbstring

Jan Schneider jan at horde.org
Sat Jul 26 01:42:55 PDT 2003


Zitat von Mike Cochrane <mike at graftonhall.co.nz>:

> Just been doing a bit of profiling of folders.php.
>
> Noticed that iconv never actually achieves anything here. If fails on all
> 292
> calls in String::convertCharset() when I load folders.php.
>
> Unloading the iconv extension results in an 11% reduction in cpu time to
> generate the page.
>
> What is the reason for favouring iconv over mbstring? Iconv fails with

Because iconv has much better results and succeeds in much more cases than
mbstring. Normally.

> this
> error message:
> [26-Jul-2003 15:06:42] PHP Notice:  iconv(): Wrong charset, cannot
> convert from
> `UTF7-IMAP' to `ISO-8859-1//TRANSLIT' in
> i:\httpd\clean\horde\lib\String.php on
> line 92
>
> Is this something specific to me, windows or just bad luck?

This is correct because iconv doesn't know about utf7-imap, only mbstring.
Thus all folder name conversions in IMP will be done by mbstring (if
available) and most of the message conversions will be done by iconv (if
available).

Jan.

--
http://www.horde.org - The Horde Project
http://www.ammma.de - discover your knowledge
http://www.tip4all.de - Deine private Tippgemeinschaft


More information about the dev mailing list