in reply to Perl Encoding/Decoding Doubt: From a Novice
In order to avoid some Unicode bugs, unicode_strings is recommended. For utf-8 input and output, use open ":encoding(UTF-8)". However it is probably wise to respect the local configuration, which is what I do instead in the code below. Lastly you need to tell the perl interpreter that the literal strings in your source code are utf-8, via "use utf8;".
So with any luck, the code below should work:
use strict; use warnings; use feature 'unicode_strings'; use open ":locale"; use utf8; print "Çrçös\n"; print "Çirçös\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Perl Encoding/Decoding Doubt: From a Novice
by ppremkumar (Novice) on Jul 05, 2013 at 05:19 UTC |