in reply to Re^7: Getting mad with CGI::Application and utf8
in thread Getting mad with CGI::Application and utf8
Let me repeat the question
Do you expect me to repeat the answer too? :)
If your subroutine or module specifically only handles binary strings, I'd recommend documenting it as such, and downgrading the string that you receive:
That's more or less what Perl does in its binary operators, like print.my $copy = $foo; utf8::downgrade($copy) or utf8::encode($copy) && carp "Wide character +in operation";
Whatever you do, though, never assume that the absence of the flag means it's not a text string!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^9: Getting mad with CGI::Application and utf8
by moritz (Cardinal) on Feb 27, 2008 at 11:19 UTC | |
by Juerd (Abbot) on Feb 27, 2008 at 13:26 UTC |