From: Evgeniy Kobzev <evgenik@diamonds.ru>
To: ALT Linux Sisyphus discussion list <sisyphus@altlinux.ru>
Subject: [sisyphus] Squirrelmail и ошибка декодирования.
Date: Tue, 28 Sep 2004 10:30:12 +0400
Message-ID: <415904F4.10201@diamonds.ru> (raw)
Тут пролетала как то эта тема, и предлагался грязный хак путем
комментирования следующих строчек в
/var/www/html/squirrelmail/functions/decode/*.php
#if (! ereg("[\200-\237]", $string) and ! ereg("[\241-\377]", $string) )
# return $string;
На самом деле всё гораздо прозаичнее.
Используется функция ereg(), а она не может работать с юникодом.
Чтобы она смогла понимать юникод, нужно включить "Multi-Byte String
Functions", а чтобы их включить, нужно установить php-mbstring.
И ещё поставить нужное значение параметру mbstring.func_overload
в /etc/php/<version>/mod_php/php.d/mbstring.ini
например:
; overload(replace) single byte functions by mbstring functions.
; mail(), ereg(), etc are overloaded by mb_send_mail(), mb_ereg(),
; etc. Possible values are 0,1,2,4 or combination of them.
; For example, 7 for overload everything.
; 0: No overload
; 1: Overload mail() function
; 2: Overload str*() functions
; 4: Overload ereg*() functions
mbstring.func_overload = 7
Таким образом делаем вывод:
squirrelmail с русским языком без установки php-mbstring работать не будет.
Может в зависимости?
next reply other threads:[~2004-09-28 6:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-09-28 6:30 Evgeniy Kobzev [this message]
2004-09-28 7:04 ` Evgeniy Kobzev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=415904F4.10201@diamonds.ru \
--to=evgenik@diamonds.ru \
--cc=sisyphus@altlinux.ru \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
ALT Linux Sisyphus discussions
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/sisyphus/0 sisyphus/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 sisyphus sisyphus/ http://lore.altlinux.org/sisyphus \
sisyphus@altlinux.ru sisyphus@altlinux.org sisyphus@lists.altlinux.org sisyphus@lists.altlinux.ru sisyphus@lists.altlinux.com sisyphus@linuxteam.iplabs.ru sisyphus@list.linux-os.ru
public-inbox-index sisyphus
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.sisyphus
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git