Clear questions and runnable code get the best and fastest answer |
|
PerlMonks |
Re^2: utf8 characters in tr/// or s///by b10m (Vicar) |
on Oct 05, 2008 at 20:03 UTC ( [id://715461]=note: print w/replies, xml ) | Need Help?? |
When you fetch utf8 texrt from mysql, you should always run it through Encode::decode("utf8",...) -- update: or equivalent, as shown by ikegami When using a fairly recent version of DBD::mysql, you can use the mysql_enable_utf8 option. Or, to quote: This attribute determines whether DBD::mysql should assume strings stored in the database are utf8. This feature defaults to off. and yes, this is experimental, but seemed to work fairly stable in my tests.
-- b10m
In Section
Seekers of Perl Wisdom
|
|