List Info

Thread: truncate - utf8




truncate - utf8
user name
2007-01-19 13:24:36
Hello,

I'm use utf-8 database, file / template encoding, headers,
etc. The
truncate modifier use strlen() function, the func doesn't
work for
extended chars, example: árvívtûrõ tükörfúrógép

echo strlen('árvívtûrõ tükörfúrógép'); // 31
echo mb_strlen('árvívtûrõ tükörfúrógép', 'utf-8'); // 22

-- 
udv, Benjamin

-- 
Smarty Development Mailing List (http://smarty.php.net/)
To unsubscribe, visit: http://www.php.net/unsub
.php


[1]

about | contact  Other archives ( Real Estate discussion Medical topics )