From: "Денис Смирнов" <mithraen@altlinux.ru>
To: "культурный офтопик" <smoke-room@lists.altlinux.org>
Subject: [room] Вопрос по PHP (или I Hate PHP)
Date: Sun, 11 Feb 2007 04:16:24 +0300
Message-ID: <20070211011624.GA397@mw.local.seiros.ru> (raw)
Пишу код:
<?php
$a = strlen("привет");
$b = strlen("привет привет");
echo $a." ".$b;
?>
естественно в utf-8. Выдает он, разумеется, '12 25'. Разумеется
аналогичный код в perl если не забыть про use utf8 дает более правильный
ответ.
Какой кувалдой долбануть PHP, чтобы str* с уникодом работала как надо, а
не черт знает как?
/me начинает радоваться что изначально у меня большая часть кода
генерируется, а логики на PHP минимум -- написать компилятор будет вполне
реально. Свалю на perl опять, блин. Он хоть и уродец, но зато логику как
его авторов, так и авторов большинства модулей я могу понять.
--
С уважением, Денис
http://freesource.info
----------------------------------------------------------------------------
<drF_ckoff> вы мне мозги не парьте, они у меня и так слабые
next reply other threads:[~2007-02-11 1:16 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-11 1:16 Денис Смирнов [this message]
2007-02-11 5:40 ` Anatol B. Bazyukin
2007-02-11 20:43 ` Денис Смирнов
2007-02-12 6:00 ` Eugene Prokopiev
2007-02-13 10:02 ` Денис Смирнов
2007-02-13 12:21 ` Damir Shayhutdinov
2007-02-13 16:16 ` Денис Смирнов
2007-02-13 16:37 ` Damir Shayhutdinov
2007-02-14 19:07 ` Денис Смирнов
2007-02-14 15:15 ` Michael Shigorin
2007-02-15 10:45 ` Денис Смирнов
2007-02-13 18:29 ` Andrey Rahmatullin
2007-02-14 19:03 ` Денис Смирнов
2007-02-14 14:59 ` Andrey Rahmatullin
2007-02-15 10:26 ` Денис Смирнов
2007-02-15 16:02 ` Andrey Rahmatullin
2007-02-17 11:55 ` Денис Смирнов
2007-02-14 15:11 ` Michael Shigorin
2007-02-15 10:45 ` Денис Смирнов
2007-02-17 17:22 ` Alexander Borovsky
2007-02-24 11:51 ` Денис Смирнов
2007-02-18 14:22 ` Eugene Prokopiev
2007-02-19 6:40 ` Eugene Prokopiev
2007-02-24 12:02 ` Денис Смирнов
2007-02-24 15:28 ` Eugene Prokopiev
2007-02-25 9:18 ` Денис Смирнов
2007-02-25 21:55 ` Eugene Prokopiev
2007-02-25 22:16 ` Денис Смирнов
2007-02-19 11:02 ` Денис Смирнов
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=20070211011624.GA397@mw.local.seiros.ru \
--to=mithraen@altlinux.ru \
--cc=smoke-room@lists.altlinux.org \
/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
Культурный офтопик
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/smoke-room/0 smoke-room/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 smoke-room smoke-room/ http://lore.altlinux.org/smoke-room \
smoke-room@lists.altlinux.org smoke-room@lists.altlinux.ru smoke-room@lists.altlinux.com smoke-room@altlinux.ru smoke-room@altlinux.org smoke-room@altlinux.com
public-inbox-index smoke-room
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.smoke-room
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git