[i18n] Internationalization for imp search

persian-horde@metanetworking.com persian-horde at metanetworking.com
Sat May 14 18:53:04 PDT 2005


Hello All,

Some locales including persian, japaneese and chinese which use from
specific charsets, could not search correctly when they use imp mailbox
search.
(see i18n mailing list, http://lists.horde.org/archives/i18n/Week-of-Mon-
20050509/thread.html)

This problem has been addressed in PHP >= 4.3.3 by including a charset
option, in imap_search function. But the Framework "IMAP_Search" library,
does not use from this argument, thus some locales have problem in
searching.

We fixed this issue temporariliy for our locale by sending an additional
charset parameter in Framework/Horde/IMAP/Search.php, e.g:
Line 173:

- if (!($indices = @imap_search($imap, $ob->fullquery, SE_UID))) {
+ if (!($indices = @imap_search($imap, $ob->fullquery, SE_UID,"utf-8"))) {


Our question is that how can we enhance the search function so it works
for all locales in general. One way is to pass the $nls['charsets']
[$language] to this Class. But not all locales have an specific charset
defined in nls.php.

Your comments are appreciated,

Thanks
Persian Horde Team





More information about the i18n mailing list